cui/source/customize/acccfg.cxx | 16 ---------------- cui/source/customize/eventdlg.cxx | 2 +- cui/source/customize/macropg.cxx | 27 +++++++++++++++------------ cui/source/customize/macropg_impl.hxx | 2 +- cui/source/factory/dlgfact.cxx | 3 --- cui/source/inc/acccfg.hxx | 24 ------------------------ cui/source/inc/connect.hxx | 2 +- cui/source/inc/headertablistbox.hxx | 29 +++++++++++++---------------- cui/source/tabpages/macroass.cxx | 4 ++-- 9 files changed, 33 insertions(+), 76 deletions(-)
New commits: commit 945394d8679e1f8c61d4cdab53420192a53472a6 Author: Caolán McNamara <[email protected]> Date: Wed Jan 22 16:34:32 2014 +0000 rename _HeaderTabListBox to MacroEventListBox Change-Id: I310b1e0c48723b383b9eb15b8df763bac3bfd687 diff --git a/cui/source/customize/eventdlg.cxx b/cui/source/customize/eventdlg.cxx index abe8013..2fcb6cf 100644 --- a/cui/source/customize/eventdlg.cxx +++ b/cui/source/customize/eventdlg.cxx @@ -63,7 +63,7 @@ SvxEventConfigPage::SvxEventConfigPage( Window *pParent, const SfxItemSet& rSet, { mpImpl->pStrEvent = new OUString( CUI_RES( STR_EVENT )); mpImpl->pAssignedMacro = new OUString( CUI_RES( STR_ASSMACRO )); - mpImpl->pEventLB = new _HeaderTabListBox( this, CUI_RES( LB_EVENT )); + mpImpl->pEventLB = new MacroEventListBox( this, CUI_RES( LB_EVENT )); mpImpl->pAssignFT = new FixedText( this, CUI_RES( FT_ASSIGN )); mpImpl->pAssignPB = new PushButton( this, CUI_RES( PB_ASSIGN )); mpImpl->pDeletePB = new PushButton( this, CUI_RES( PB_DELETE )); diff --git a/cui/source/customize/macropg.cxx b/cui/source/customize/macropg.cxx index db9a6a8..b362a99 100644 --- a/cui/source/customize/macropg.cxx +++ b/cui/source/customize/macropg.cxx @@ -99,9 +99,9 @@ static long nTabs[] = #define LB_MACROS_ITEMPOS 2 -IMPL_LINK( _HeaderTabListBox, HeaderEndDrag_Impl, HeaderBar*, pBar ) +IMPL_LINK( MacroEventListBox, HeaderEndDrag_Impl, HeaderBar*, pBar ) { - DBG_ASSERT( pBar == &maHeaderBar, "*_HeaderTabListBox::HeaderEndDrag_Impl: something is wrong here..." ); + DBG_ASSERT( pBar == &maHeaderBar, "*MacroEventListBox::HeaderEndDrag_Impl: something is wrong here..." ); (void)pBar; if( !maHeaderBar.GetCurItemId() ) @@ -133,7 +133,7 @@ IMPL_LINK( _HeaderTabListBox, HeaderEndDrag_Impl, HeaderBar*, pBar ) return 1; } -bool _HeaderTabListBox::Notify( NotifyEvent& rNEvt ) +bool MacroEventListBox::Notify( NotifyEvent& rNEvt ) { bool nRet = Control::Notify( rNEvt ); @@ -146,7 +146,7 @@ bool _HeaderTabListBox::Notify( NotifyEvent& rNEvt ) return nRet; } -_HeaderTabListBox::_HeaderTabListBox( Window* pParent, const ResId& rId ) +MacroEventListBox::MacroEventListBox( Window* pParent, const ResId& rId ) : Control( pParent, rId ) , maHeaderBar( this, WB_BUTTONSTYLE | WB_BOTTOMBORDER ) , maListBox( this, WB_HSCROLL | WB_CLIPCHILDREN | WB_TABSTOP ) @@ -157,7 +157,7 @@ _HeaderTabListBox::_HeaderTabListBox( Window* pParent, const ResId& rId ) maListBox.EnableCellFocus(); } -void _HeaderTabListBox::Resize() +void MacroEventListBox::Resize() { Control::Resize(); @@ -174,23 +174,23 @@ void _HeaderTabListBox::Resize() maListBox.SetPosSizePixel( aPnt, aSize ); } -void _HeaderTabListBox::ConnectElements( void ) +void MacroEventListBox::ConnectElements( void ) { Resize(); // set handler - maHeaderBar.SetEndDragHdl( LINK( this, _HeaderTabListBox, HeaderEndDrag_Impl ) ); + maHeaderBar.SetEndDragHdl( LINK( this, MacroEventListBox, HeaderEndDrag_Impl ) ); maListBox.InitHeaderBar( &maHeaderBar ); } -void _HeaderTabListBox::Show( sal_Bool bVisible, sal_uInt16 nFlags ) +void MacroEventListBox::Show( sal_Bool bVisible, sal_uInt16 nFlags ) { maListBox.Show( bVisible, nFlags ); maHeaderBar.Show( bVisible, nFlags ); } -void _HeaderTabListBox::Enable( bool bEnable, bool bChild ) +void MacroEventListBox::Enable( bool bEnable, bool bChild ) { maListBox.Enable( bEnable, bChild ); maHeaderBar.Enable( bEnable, bChild ); @@ -818,7 +818,7 @@ SvxMacroTabPage::SvxMacroTabPage( Window* pParent, const Reference< frame::XFram { mpImpl->pStrEvent = new OUString( CUI_RES( STR_EVENT ) ); mpImpl->pAssignedMacro = new OUString( CUI_RES( STR_ASSMACRO ) ); - mpImpl->pEventLB = new _HeaderTabListBox( this, CUI_RES( LB_EVENT ) ); + mpImpl->pEventLB = new MacroEventListBox( this, CUI_RES( LB_EVENT ) ); mpImpl->pAssignFT = new FixedText( this, CUI_RES( FT_ASSIGN ) ); mpImpl->pAssignPB = new PushButton( this, CUI_RES( PB_ASSIGN ) ); mpImpl->pDeletePB = new PushButton( this, CUI_RES( PB_DELETE ) ); diff --git a/cui/source/customize/macropg_impl.hxx b/cui/source/customize/macropg_impl.hxx index 6de18f0..c467137 100644 --- a/cui/source/customize/macropg_impl.hxx +++ b/cui/source/customize/macropg_impl.hxx @@ -34,7 +34,7 @@ public: Image* pComponentImg; OUString* pStrEvent; OUString* pAssignedMacro; - _HeaderTabListBox* pEventLB; + MacroEventListBox* pEventLB; sal_Bool bReadOnly; sal_Bool bIDEDialogMode; }; diff --git a/cui/source/inc/headertablistbox.hxx b/cui/source/inc/headertablistbox.hxx index b39c36a..0e01475 100644 --- a/cui/source/inc/headertablistbox.hxx +++ b/cui/source/inc/headertablistbox.hxx @@ -24,7 +24,7 @@ #include <svtools/svtabbx.hxx> -class _HeaderTabListBox : public Control +class MacroEventListBox : public Control { private: HeaderBar maHeaderBar; @@ -33,7 +33,7 @@ protected: DECL_LINK( HeaderEndDrag_Impl, HeaderBar* ); virtual bool Notify( NotifyEvent& rNEvt ); public: - _HeaderTabListBox( Window* pParent, const ResId& rId ); + MacroEventListBox( Window* pParent, const ResId& rId ); void Resize(); diff --git a/cui/source/tabpages/macroass.cxx b/cui/source/tabpages/macroass.cxx index 2bc3630..f5044ce 100644 --- a/cui/source/tabpages/macroass.cxx +++ b/cui/source/tabpages/macroass.cxx @@ -50,7 +50,7 @@ public: PushButton* pDeletePB; OUString* pStrEvent; OUString* pAssignedMacro; - _HeaderTabListBox* pEventLB; + MacroEventListBox* pEventLB; SfxConfigGroupListBox_Impl* pGroupLB; FixedText* pFT_MacroLBLabel; SfxConfigFunctionListBox_Impl* pMacroLB; @@ -464,7 +464,7 @@ SfxMacroTabPage::SfxMacroTabPage( Window* pParent, const ResId& rResId, const Re { mpImpl->pStrEvent = new OUString( CUI_RES( STR_EVENT ) ); mpImpl->pAssignedMacro = new OUString( CUI_RES( STR_ASSMACRO ) ); - mpImpl->pEventLB = new _HeaderTabListBox( this, CUI_RES( LB_EVENT ) ); + mpImpl->pEventLB = new MacroEventListBox( this, CUI_RES( LB_EVENT ) ); mpImpl->pAssignPB = new PushButton( this, CUI_RES( PB_ASSIGN ) ); mpImpl->pDeletePB = new PushButton( this, CUI_RES( PB_DELETE ) ); mpImpl->pMacroFT = new FixedText( this, CUI_RES( FT_MACRO ) ); commit 696fd019ca1cb04344342ee45c7677eb0dcd1c73 Author: Caolán McNamara <[email protected]> Date: Wed Jan 22 16:31:10 2014 +0000 split resize parts of ConnectElements into ::Resize Change-Id: If338bf70537883e575e9137fe749675b301c27fe diff --git a/cui/source/customize/macropg.cxx b/cui/source/customize/macropg.cxx index 578cd5c..db9a6a8 100644 --- a/cui/source/customize/macropg.cxx +++ b/cui/source/customize/macropg.cxx @@ -157,12 +157,10 @@ _HeaderTabListBox::_HeaderTabListBox( Window* pParent, const ResId& rId ) maListBox.EnableCellFocus(); } -_HeaderTabListBox::~_HeaderTabListBox() +void _HeaderTabListBox::Resize() { -} + Control::Resize(); -void _HeaderTabListBox::ConnectElements( void ) -{ // calc pos and size of header bar Point aPnt( 0, 0 ); Size aSize( maHeaderBar.CalcWindowSizePixel() ); @@ -174,6 +172,11 @@ void _HeaderTabListBox::ConnectElements( void ) aPnt.Y() += aSize.Height(); aSize.Height() = aCtrlSize.Height() - aSize.Height(); maListBox.SetPosSizePixel( aPnt, aSize ); +} + +void _HeaderTabListBox::ConnectElements( void ) +{ + Resize(); // set handler maHeaderBar.SetEndDragHdl( LINK( this, _HeaderTabListBox, HeaderEndDrag_Impl ) ); diff --git a/cui/source/inc/headertablistbox.hxx b/cui/source/inc/headertablistbox.hxx index da17876..b39c36a 100644 --- a/cui/source/inc/headertablistbox.hxx +++ b/cui/source/inc/headertablistbox.hxx @@ -33,11 +33,19 @@ protected: DECL_LINK( HeaderEndDrag_Impl, HeaderBar* ); virtual bool Notify( NotifyEvent& rNEvt ); public: - _HeaderTabListBox( Window* pParent, const ResId& rId ); - virtual ~_HeaderTabListBox(); + _HeaderTabListBox( Window* pParent, const ResId& rId ); - inline SvHeaderTabListBox& GetListBox( void ); - inline HeaderBar& GetHeaderBar( void ); + void Resize(); + + SvHeaderTabListBox& GetListBox() + { + return maListBox; + } + + HeaderBar& GetHeaderBar() + { + return maHeaderBar; + } void ConnectElements( void );/**< should be called after all manipulations on elements are done calcs real sizes depending on sizes of this */ @@ -45,17 +53,6 @@ public: void Enable( bool bEnable = true, bool bChild = true ); ///< same meaning as Windows::Enable() }; -inline SvHeaderTabListBox& _HeaderTabListBox::GetListBox( void ) -{ - return maListBox; -} - -inline HeaderBar& _HeaderTabListBox::GetHeaderBar( void ) -{ - return maHeaderBar; -} - - #endif /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ commit d9e04ae281eaf0a888c9ca9918835cc0ce94f3ed Author: Caolán McNamara <[email protected]> Date: Wed Jan 22 15:50:27 2014 +0000 comment out of data Change-Id: Id509b4ffa7f891de2435c462df01e9b75167777b diff --git a/cui/source/inc/connect.hxx b/cui/source/inc/connect.hxx index b4ce0b2..00933e0 100644 --- a/cui/source/inc/connect.hxx +++ b/cui/source/inc/connect.hxx @@ -74,7 +74,7 @@ public: virtual void PageCreated (SfxAllItemSet aSet); }; -/* Derived from SfxNoLayoutSingleTabDialog, in order to be informed about +/* Derived from SfxSingleTabDialog, in order to be informed about virtual methods by the control. */ class SvxConnectionDialog : public SfxSingleTabDialog { commit 28da94a0907ba4d34a7b6db9ae52773d1b39a533 Author: Caolán McNamara <[email protected]> Date: Wed Jan 22 15:47:56 2014 +0000 as far as I can see there is no users of SvxShortcutAssignDlg Change-Id: I624500b149abbcc6f5fb7e16f68b852d8a2c0f29 diff --git a/cui/source/customize/acccfg.cxx b/cui/source/customize/acccfg.cxx index 0968bbf..00c8c64 100644 --- a/cui/source/customize/acccfg.cxx +++ b/cui/source/customize/acccfg.cxx @@ -1538,20 +1538,4 @@ css::uno::Reference< css::frame::XModel > SfxAcceleratorConfigPage::SearchForAlr return css::uno::Reference< css::frame::XModel >(); } -SvxShortcutAssignDlg::SvxShortcutAssignDlg( Window* pParent, const uno::Reference< frame::XFrame >& rxDocumentFrame, const SfxItemSet& rSet ) - : SfxNoLayoutSingleTabDialog( pParent, rSet, 0 ) -{ - SfxTabPage* pPage = SfxAcceleratorConfigPage::Create( this, rSet ); - pPage->SetFrame( rxDocumentFrame ); - SetTabPage( pPage ); - -} - -SvxShortcutAssignDlg::~SvxShortcutAssignDlg() -{ -} - - -// .uno:InsertSymbol?Symbols:string=bla - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/cui/source/factory/dlgfact.cxx b/cui/source/factory/dlgfact.cxx index 2090e59..ea8c22d 100644 --- a/cui/source/factory/dlgfact.cxx +++ b/cui/source/factory/dlgfact.cxx @@ -1593,9 +1593,6 @@ SfxAbstractDialog* AbstractDialogFactory_Impl::CreateSfxDialog( Window* pParent, case SID_EVENTCONFIG : pDlg = new SfxMacroAssignDlg( pParent, _rxDocumentFrame, rAttr ); break; - case RID_SVXPAGE_MACROASSIGN : - pDlg = new SvxShortcutAssignDlg( pParent, _rxDocumentFrame, rAttr ); - break; case RID_SVXDLG_CHARMAP : pDlg = new SvxCharacterMap( pParent, sal_True, &rAttr ); break; diff --git a/cui/source/inc/acccfg.hxx b/cui/source/inc/acccfg.hxx index d6e7326..550de40 100644 --- a/cui/source/inc/acccfg.hxx +++ b/cui/source/inc/acccfg.hxx @@ -182,30 +182,6 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); }; - -class SfxAcceleratorConfigListBox : public ListBox -{ - void KeyInput( const KeyEvent &rKEvt ); - -public: - - SfxAcceleratorConfigListBox( Window *pParent, ResId &rResId ) : - ListBox( pParent, rResId ) {} - - void ReplaceEntry( sal_uInt16 nPos, const OUString &rStr ); - void ExpandEntry ( sal_uInt16 nPos, const OUString &rStr ); -}; - -class SvxShortcutAssignDlg : public SfxNoLayoutSingleTabDialog -{ -public: - SvxShortcutAssignDlg( - Window* pParent, - const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxDocumentFrame, - const SfxItemSet& rSet ); - virtual ~SvxShortcutAssignDlg(); -}; - #endif /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
_______________________________________________ Libreoffice-commits mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
