diff options
author | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2011-09-27 15:16:17 +0200 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2011-09-27 16:06:03 +0200 |
commit | acbeb839aa718381f13f4f3097ff17ee46e06de8 (patch) | |
tree | f2397b09da95a000ca5adedcb01b619884c41205 /sc | |
parent | baa36ed2f1f35f311e11aa630ea16e969f841303 (diff) |
move the checkboxes below the more button
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/ui/inc/namedlg.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/namedlg/namedlg.cxx | 34 | ||||
-rw-r--r-- | sc/source/ui/src/namedlg.src | 8 |
3 files changed, 40 insertions, 4 deletions
diff --git a/sc/source/ui/inc/namedlg.hxx b/sc/source/ui/inc/namedlg.hxx index 8a556234bebf..c956cc1ea209 100644 --- a/sc/source/ui/inc/namedlg.hxx +++ b/sc/source/ui/inc/namedlg.hxx @@ -188,6 +188,7 @@ private: void ScopeChanged(); void NameModified(); void BackPushed(); + void MorePushed(); void SelectionChanged(); @@ -201,6 +202,7 @@ private: DECL_LINK( SelectionChangedHdl_Impl, void* ); DECL_LINK( BackBtnHdl, void * ); DECL_LINK( ScopeChangedHdl, void* ); + DECL_LINK( MoreBtnHdl, void* ); protected: virtual void RefInputDone( sal_Bool bForced = sal_False ); diff --git a/sc/source/ui/namedlg/namedlg.cxx b/sc/source/ui/namedlg/namedlg.cxx index 47ff62909135..1e5733a9ddb7 100644 --- a/sc/source/ui/namedlg/namedlg.cxx +++ b/sc/source/ui/namedlg/namedlg.cxx @@ -304,6 +304,7 @@ void ScNameDlg::Init() maLbScope.SetSelectHdl( LINK(this, ScNameDlg, ScopeChangedHdl) ); maBtnDelete.SetClickHdl ( LINK( this, ScNameDlg, RemoveBtnHdl ) ); maBtnModify.SetClickHdl ( LINK( this, ScNameDlg, ModifyBtnHdl ) ); + maBtnMore.SetClickHdl ( LINK( this, ScNameDlg, MoreBtnHdl ) ); maBtnBack.Disable(); @@ -644,6 +645,34 @@ void ScNameDlg::ModifiedPushed() } } +namespace { + +void MoveWindow( Window& rButton, long nPixel) +{ + Point aPoint = rButton.GetPosPixel(); + aPoint.Y() += nPixel; + rButton.SetPosPixel(aPoint); +} + +} + +void ScNameDlg::MorePushed() +{ + //depending on the state of the button, move all elements beloe up/down + long nPixel = 85; + if (!maBtnMore.GetState()) + { + nPixel *= -1; + } + MoveWindow(maBtnAdd, nPixel); + MoveWindow(maBtnModify, nPixel); + MoveWindow(maBtnBack, nPixel); + MoveWindow(maBtnDelete, nPixel); + MoveWindow(maBtnHelp, nPixel); + MoveWindow(maBtnClose, nPixel); + MoveWindow(maFlDiv, nPixel); +} + IMPL_LINK( ScNameDlg, CloseBtnHdl, void *, EMPTYARG ) { Close(); @@ -698,4 +727,9 @@ IMPL_LINK( ScNameDlg, ScopeChangedHdl, void*, EMPTYARG ) return 0; } +IMPL_LINK( ScNameDlg, MoreBtnHdl, void*, EMPTYARG ) +{ + MorePushed(); + return 0; +} /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sc/source/ui/src/namedlg.src b/sc/source/ui/src/namedlg.src index be1c84c83e25..00c5c82f046c 100644 --- a/sc/source/ui/src/namedlg.src +++ b/sc/source/ui/src/namedlg.src @@ -148,7 +148,7 @@ ModelessDialog RID_SCDLG_NAMES CheckBox BTN_PRINTAREA { HelpID = "sc:CheckBox:RID_SCDLG_NAMES:BTN_PRINTAREA"; - Pos = MAP_APPFONT ( 6 , 255 ) ; + Pos = MAP_APPFONT ( 6 , 208 ) ; Size = MAP_APPFONT ( 60 , 10 ) ; Text [ en-US ] = "~Print range" ; TabStop = TRUE ; @@ -156,7 +156,7 @@ ModelessDialog RID_SCDLG_NAMES CheckBox BTN_CRITERIA { HelpID = "sc:CheckBox:RID_SCDLG_NAMES:BTN_CRITERIA"; - Pos = MAP_APPFONT ( 6 , 270 ) ; + Pos = MAP_APPFONT ( 6 , 223 ) ; Size = MAP_APPFONT ( 60 , 10 ) ; Text [ en-US ] = "~Filter" ; TabStop = TRUE ; @@ -164,7 +164,7 @@ ModelessDialog RID_SCDLG_NAMES CheckBox BTN_ROWHEADER { HelpID = "sc:CheckBox:RID_SCDLG_NAMES:BTN_ROWHEADER"; - Pos = MAP_APPFONT ( 110, 270 ) ; + Pos = MAP_APPFONT ( 110, 223 ) ; Size = MAP_APPFONT ( 82 , 10 ) ; Text [ en-US ] = "Repeat ~row" ; TabStop = TRUE ; @@ -172,7 +172,7 @@ ModelessDialog RID_SCDLG_NAMES CheckBox BTN_COLHEADER { HelpID = "sc:CheckBox:RID_SCDLG_NAMES:BTN_COLHEADER"; - Pos = MAP_APPFONT ( 110 , 255 ) ; + Pos = MAP_APPFONT ( 110 , 208 ) ; Size = MAP_APPFONT ( 82 , 10 ) ; Text [ en-US ] = "Repeat ~column" ; TabStop = TRUE ; |