summaryrefslogtreecommitdiff
path: root/svx/inc/svx/colrctrl.hxx
diff options
context:
space:
mode:
authorVladimir Glazounov <vg@openoffice.org>2007-04-11 14:42:03 +0000
committerVladimir Glazounov <vg@openoffice.org>2007-04-11 14:42:03 +0000
commit7699064b7a6bd508f9ae22874f22bad1ad60a05e (patch)
tree539132dbfb2da91d93753aaa7af9e1d51f38c8cb /svx/inc/svx/colrctrl.hxx
parente902e01fe9d13eb85bb144f7a54e78e1c43b01f4 (diff)
INTEGRATION: CWS hedaburemove01 (1.1.2); FILE ADDED
2007/02/09 16:52:59 vg 1.1.2.1: #72503# get rid of hedabu procedure: Moving headers to svx/inc/svx and correspondent necessary changes
Diffstat (limited to 'svx/inc/svx/colrctrl.hxx')
-rw-r--r--svx/inc/svx/colrctrl.hxx167
1 files changed, 167 insertions, 0 deletions
diff --git a/svx/inc/svx/colrctrl.hxx b/svx/inc/svx/colrctrl.hxx
new file mode 100644
index 000000000000..9608e98660f0
--- /dev/null
+++ b/svx/inc/svx/colrctrl.hxx
@@ -0,0 +1,167 @@
+/*************************************************************************
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: colrctrl.hxx,v $
+ *
+ * $Revision: 1.2 $
+ *
+ * last change: $Author: vg $ $Date: 2007-04-11 15:41:39 $
+ *
+ * The Contents of this file are made available subject to
+ * the terms of GNU Lesser General Public License Version 2.1.
+ *
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2005 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ ************************************************************************/
+#ifndef _SVX_COLRCTRL_HXX
+#define _SVX_COLRCTRL_HXX
+
+#ifndef _SFXDOCKWIN_HXX //autogen
+#include <sfx2/dockwin.hxx>
+#endif
+#ifndef _SFX_CHILDWIN_HXX //autogen
+#include <sfx2/childwin.hxx>
+#endif
+#ifndef _VALUESET_HXX //autogen
+#include <svtools/valueset.hxx>
+#endif
+#ifndef _TRANSFER_HXX //autogen
+#include <svtools/transfer.hxx>
+#endif
+#ifndef _SFXLSTNER_HXX //autogen
+#include <svtools/lstner.hxx>
+#endif
+
+#ifndef INCLUDED_SVXDLLAPI_H
+#include "svx/svxdllapi.h"
+#endif
+
+class XColorTable;
+class SvData;
+
+/*************************************************************************
+|*
+|* SvxColorValueSet
+|*
+\************************************************************************/
+
+class SvxColorValueSet : public ValueSet, public DragSourceHelper
+{
+ using ValueSet::StartDrag;
+
+private:
+
+ BOOL bLeft;
+ Point aDragPosPixel;
+
+protected:
+
+ void DoDrag();
+
+ // ValueSet
+ virtual void MouseButtonDown( const MouseEvent& rMEvt );
+ virtual void MouseButtonUp( const MouseEvent& rMEvt );
+ virtual void Command(const CommandEvent& rCEvt );
+
+ // DragSourceHelper
+ virtual void StartDrag( sal_Int8 nAction, const Point& rPtPixel );
+
+ DECL_STATIC_LINK(SvxColorValueSet, ExecDragHdl, void*);
+
+public:
+ SvxColorValueSet( Window* pParent, WinBits nWinStyle = WB_ITEMBORDER );
+ SvxColorValueSet( Window* pParent, const ResId& rResId );
+
+ BOOL IsLeftButton() const { return bLeft; }
+};
+
+/*************************************************************************
+|*
+|* Ableitung vom SfxChildWindow als "Behaelter" fuer Controller
+|*
+\************************************************************************/
+
+class SVX_DLLPUBLIC SvxColorChildWindow : public SfxChildWindow
+{
+ public:
+ SvxColorChildWindow( Window*, USHORT, SfxBindings*,
+ SfxChildWinInfo* );
+
+ SFX_DECL_CHILDWINDOW(SvxColorChildWindow);
+};
+
+/*************************************************************************
+|*
+|* SvxColorDockingWindow
+|*
+\************************************************************************/
+
+class SvxColorDockingWindow : public SfxDockingWindow, public SfxListener
+{
+ friend class SvxColorChildWindow;
+
+private:
+ XColorTable* pColorTable;
+ SvxColorValueSet aColorSet;
+ USHORT nLeftSlot;
+ USHORT nRightSlot;
+ USHORT nCols;
+ USHORT nLines;
+ long nCount;
+ Size aColorSize;
+ Size aItemSize;
+
+//#if 0 // _SOLAR__PRIVATE
+ void FillValueSet();
+ void SetSize();
+ DECL_LINK( SelectHdl, void * );
+
+ /** This function is called when the window gets the focus. It grabs
+ the focus to the color value set so that it can be controlled with
+ the keyboard.
+ */
+ virtual void GetFocus (void);
+//#endif
+
+protected:
+ virtual BOOL Close();
+ virtual void Resize();
+ virtual void Resizing( Size& rSize );
+
+public:
+ SvxColorDockingWindow( SfxBindings* pBindings,
+ SfxChildWindow *pCW,
+ Window* pParent,
+ const ResId& rResId );
+ ~SvxColorDockingWindow();
+
+ virtual void SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType,
+ const SfxHint& rHint, const TypeId& rHintType );
+
+ void SetSlotIDs( USHORT nLeft, USHORT nRight )
+ { nLeftSlot = nLeft; nRightSlot = nRight; }
+
+ virtual long Notify( NotifyEvent& rNEvt );
+};
+
+#endif
+