diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-01-22 16:31:10 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-01-22 16:35:27 +0000 |
commit | 696fd019ca1cb04344342ee45c7677eb0dcd1c73 (patch) | |
tree | b8dc6234ae1318508ef90ac27332ca567c7c5560 /cui | |
parent | d9e04ae281eaf0a888c9ca9918835cc0ce94f3ed (diff) |
split resize parts of ConnectElements into ::Resize
Change-Id: If338bf70537883e575e9137fe749675b301c27fe
Diffstat (limited to 'cui')
-rw-r--r-- | cui/source/customize/macropg.cxx | 11 | ||||
-rw-r--r-- | cui/source/inc/headertablistbox.hxx | 27 |
2 files changed, 19 insertions, 19 deletions
diff --git a/cui/source/customize/macropg.cxx b/cui/source/customize/macropg.cxx index 578cd5cd42da..db9a6a8104d4 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 da178764035b..b39c36a7c178 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: */ |