summaryrefslogtreecommitdiff
path: root/cui/source/tabpages
diff options
context:
space:
mode:
authorOlivier Hallot <olivier.hallot@alta.org.br>2013-03-07 22:04:20 -0300
committerCaolán McNamara <caolanm@redhat.com>2013-03-08 09:27:14 +0000
commitd400bb0d33acd81226fbeea56eaa9ae02a8b1c05 (patch)
tree1bcbd9d151961664e0f6244f9a7df258238de347 /cui/source/tabpages
parent3d4723f80a37e719359ad78ad063bc39ac28cd32 (diff)
Small improvement in page widget ui
Save a coupe of bytes and better use of widget features Change-Id: I6860339a8b62c7e95605a0abc47e99d7ef49696b Reviewed-on: https://gerrit.libreoffice.org/2590 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'cui/source/tabpages')
-rw-r--r--cui/source/tabpages/page.cxx27
1 files changed, 10 insertions, 17 deletions
diff --git a/cui/source/tabpages/page.cxx b/cui/source/tabpages/page.cxx
index fe2c43d90fa8..f04d6a6ce811 100644
--- a/cui/source/tabpages/page.cxx
+++ b/cui/source/tabpages/page.cxx
@@ -223,8 +223,8 @@ SvxPageDescPage::SvxPageDescPage( Window* pParent, const SfxItemSet& rAttr ) :
get(m_pAdaptBox,"checkAdaptBox");
// Strings stored in UI
- get(m_pInsideText,"labelInner");
- get(m_pOutsideText,"labelOuter");
+ get(m_pInsideLbl,"labelInner");
+ get(m_pOutsideLbl,"labelOuter");
get(m_pPrintRangeQueryText,"labelMsg");
bBorderModified = sal_False;
@@ -370,11 +370,6 @@ SvxPageDescPage::~SvxPageDescPage()
void SvxPageDescPage::Init_Impl()
{
- aLeftText = m_pLeftMarginLbl->GetText();
- aRightText = m_pRightMarginLbl->GetText();
- aInsideText = m_pInsideText->GetText();
- aOutsideText = m_pOutsideText->GetText();
-
// adjust the handler
m_pLayoutBox->SetSelectHdl( LINK( this, SvxPageDescPage, LayoutHdl_Impl ) );
m_pPaperSizeBox->SetDropDownLineCount(10);
@@ -900,19 +895,17 @@ IMPL_LINK_NOARG(SvxPageDescPage, LayoutHdl_Impl)
if ( nPos == SVX_PAGE_MIRROR )
{
- if ( m_pLeftMarginLbl->GetText() != aInsideText )
- m_pLeftMarginLbl->SetText( aInsideText );
-
- if ( m_pRightMarginLbl->GetText() != aOutsideText )
- m_pRightMarginLbl->SetText( aOutsideText );
+ m_pLeftMarginLbl->Hide();
+ m_pRightMarginLbl->Hide();
+ m_pInsideLbl->Show();
+ m_pOutsideLbl->Show();
}
else
{
- if ( m_pLeftMarginLbl->GetText() != aLeftText )
- m_pLeftMarginLbl->SetText( aLeftText );
-
- if ( m_pRightMarginLbl->GetText() != aRightText )
- m_pRightMarginLbl->SetText( aRightText );
+ m_pLeftMarginLbl->Show();
+ m_pRightMarginLbl->Show();
+ m_pInsideLbl->Hide();
+ m_pOutsideLbl->Hide();
}
UpdateExample_Impl( true );
return 0;