From 5cdc28997bbfbf6732b250200f2eb07359f81390 Mon Sep 17 00:00:00 2001 From: os Date: Tue, 28 Dec 2010 15:25:10 +0100 Subject: #i115915# paper size box needs valid selection --- cui/source/tabpages/page.cxx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'cui') diff --git a/cui/source/tabpages/page.cxx b/cui/source/tabpages/page.cxx index e2ee5b11af8f..d3814537eaf2 100644 --- a/cui/source/tabpages/page.cxx +++ b/cui/source/tabpages/page.cxx @@ -605,6 +605,7 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) ResStringArray aPaperAry( CUI_RES( nAryId ) ); sal_uInt32 nCnt = aPaperAry.Count(); + USHORT nUserPos = LISTBOX_ENTRY_NOTFOUND; for ( sal_uInt32 i = 0; i < nCnt; ++i ) { String aStr = aPaperAry.GetString(i); @@ -614,9 +615,11 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) if ( eSize == ePaper ) nActPos = nPos; + if( eSize == PAPER_USER ) + nUserPos = nPos; } - // aktuelles Papierformat selektieren - aPaperSizeBox.SelectEntryPos( nActPos ); + // preselect current paper format - #115915#: ePaper might not be in aPaperSizeBox so use PAPER_USER instead + aPaperSizeBox.SelectEntryPos( nActPos != LISTBOX_ENTRY_NOTFOUND ? nActPos : nUserPos ); // Applikationsspezifisch -- cgit v1.2.3 From 883e2b11250a7bd9b97b20a5ef1d4d87fab42bdd Mon Sep 17 00:00:00 2001 From: os Date: Wed, 16 Feb 2011 11:53:46 +0100 Subject: USHORT removed --- cui/source/tabpages/page.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) mode change 100644 => 100755 cui/source/tabpages/page.cxx (limited to 'cui') diff --git a/cui/source/tabpages/page.cxx b/cui/source/tabpages/page.cxx old mode 100644 new mode 100755 index 4be479d9f4f6..5643a2f66a8a --- a/cui/source/tabpages/page.cxx +++ b/cui/source/tabpages/page.cxx @@ -605,7 +605,7 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) ResStringArray aPaperAry( CUI_RES( nAryId ) ); sal_uInt32 nCnt = aPaperAry.Count(); - USHORT nUserPos = LISTBOX_ENTRY_NOTFOUND; + sal_uInt16 nUserPos = LISTBOX_ENTRY_NOTFOUND; for ( sal_uInt32 i = 0; i < nCnt; ++i ) { String aStr = aPaperAry.GetString(i); -- cgit v1.2.3