1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: tbxform.hxx,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef _SVX_TBXFORM_HXX
31 #define _SVX_TBXFORM_HXX
33 #include <sfx2/tbxctrl.hxx>
34 #include <vcl/field.hxx>
35 #include <vcl/dialog.hxx>
37 #ifndef _SV_BUTTON_HXX //autogen
38 #include <vcl/button.hxx>
41 //========================================================================
42 class SvxFmAbsRecWin
: public NumericField
44 SfxToolBoxControl
* m_pController
;
45 // for invalidating our content whe losing the focus
47 SvxFmAbsRecWin( Window
* _pParent
, SfxToolBoxControl
* _pController
);
50 virtual void KeyInput( const KeyEvent
& rKeyEvt
);
51 virtual void LoseFocus();
54 virtual void FirePosition( sal_Bool _bForce
);
58 //========================================================================
59 class SvxFmConfigWin
: public SfxPopupWindow
62 DECL_LINK( TbxSelectHdl
, ToolBox
* );
65 SvxFmConfigWin( USHORT nId
, ResId aRIdWin
, ResId aRIdTbx
);
69 virtual void PopupModeEnd();
73 //========================================================================
74 class SvxFmTbxCtlConfig
: public SfxToolBoxControl
80 using SfxToolBoxControl::Select
;
83 SFX_DECL_TOOLBOX_CONTROL();
85 SvxFmTbxCtlConfig( USHORT nSlotId
, USHORT nId
, ToolBox
& rTbx
);
86 ~SvxFmTbxCtlConfig() {}
88 virtual void Select( USHORT nModifier
);
89 virtual void StateChanged( USHORT nSID
, SfxItemState eState
,
90 const SfxPoolItem
* pState
);
91 virtual SfxPopupWindowType
GetPopupWindowType() const;
92 virtual SfxPopupWindow
* CreatePopupWindow();
95 //========================================================================
97 class SvxFmTbxCtlAbsRec
: public SfxToolBoxControl
100 SFX_DECL_TOOLBOX_CONTROL();
102 SvxFmTbxCtlAbsRec( USHORT nSlotId
, USHORT nId
, ToolBox
& rTbx
);
103 ~SvxFmTbxCtlAbsRec();
105 virtual Window
* CreateItemWindow( Window
* pParent
);
107 virtual void StateChanged( USHORT nSID
, SfxItemState eState
,
108 const SfxPoolItem
* pState
);
111 //========================================================================
112 class SvxFmTbxCtlRecText
: public SfxToolBoxControl
115 SFX_DECL_TOOLBOX_CONTROL();
117 SvxFmTbxCtlRecText( USHORT nSlotId
, USHORT nId
, ToolBox
& rTbx
);
118 ~SvxFmTbxCtlRecText();
120 virtual Window
* CreateItemWindow( Window
* pParent
);
123 //========================================================================
124 class SvxFmTbxCtlRecFromText
: public SfxToolBoxControl
127 SFX_DECL_TOOLBOX_CONTROL();
129 SvxFmTbxCtlRecFromText( USHORT nSlotId
, USHORT nId
, ToolBox
& rTbx
);
130 ~SvxFmTbxCtlRecFromText();
132 virtual Window
* CreateItemWindow( Window
* pParent
);
135 //========================================================================
136 class SvxFmTbxCtlRecTotal
: public SfxToolBoxControl
138 FixedText
* pFixedText
;
141 SFX_DECL_TOOLBOX_CONTROL();
143 SvxFmTbxCtlRecTotal( USHORT nSlotId
, USHORT nId
, ToolBox
& rTbx
);
144 ~SvxFmTbxCtlRecTotal();
146 virtual Window
* CreateItemWindow( Window
* pParent
);
147 virtual void StateChanged( USHORT nSID
, SfxItemState eState
,
148 const SfxPoolItem
* pState
);
151 //========================================================================
152 class SvxFmTbxNextRec
: public SfxToolBoxControl
155 SFX_DECL_TOOLBOX_CONTROL();
156 SvxFmTbxNextRec( USHORT nSlotId
, USHORT nId
, ToolBox
& rTbx
);
159 //========================================================================
160 class SvxFmTbxPrevRec
: public SfxToolBoxControl
163 SFX_DECL_TOOLBOX_CONTROL();
164 SvxFmTbxPrevRec( USHORT nSlotId
, USHORT nId
, ToolBox
& rTbx
);