From e3f11c10d8cc759d01afa4b8fd8bd98c81a03119 Mon Sep 17 00:00:00 2001 From: "Chr. Rossmanith" Date: Mon, 21 Jan 2013 14:32:09 +0100 Subject: Changed SetText() / GetText() to take/return OUString replaced lots of Len() with isEmpty() Change-Id: I6b82d48245ee2a0782e05a326f7934e9357227d0 Reviewed-on: https://gerrit.libreoffice.org/1795 Reviewed-by: Michael Stahl Tested-by: Michael Stahl --- basic/source/runtime/inputbox.cxx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'basic') diff --git a/basic/source/runtime/inputbox.cxx b/basic/source/runtime/inputbox.cxx index 8a03001ef4f6..14fe7f103154 100644 --- a/basic/source/runtime/inputbox.cxx +++ b/basic/source/runtime/inputbox.cxx @@ -33,7 +33,7 @@ class SvRTLInputBox : public ModalDialog OKButton aOk; CancelButton aCancel; FixedText aPromptText; - String aText; + OUString aText; void PositionDialog( long nXTwips, long nYTwips, const Size& rDlgSize ); void InitButtons( const Size& rDlgSize ); @@ -45,7 +45,7 @@ class SvRTLInputBox : public ModalDialog public: SvRTLInputBox( Window* pParent, const String& rPrompt, const String& rTitle, const String& rDefault, long nXTwips = -1, long nYTwips = -1 ); - String GetText() const { return aText; } + OUString GetText() const { return aText; } }; SvRTLInputBox::SvRTLInputBox( Window* pParent, const String& rPrompt, @@ -65,12 +65,12 @@ SvRTLInputBox::SvRTLInputBox( Window* pParent, const String& rPrompt, aCancel.Show(); aEdit.Show(); aPromptText.Show(); - SetText( rTitle ); + SetText( OUString(rTitle) ); Font aFont( GetFont()); Color aColor( GetBackground().GetColor() ); aFont.SetFillColor( aColor ); aEdit.SetFont( aFont ); - aEdit.SetText( rDefault ); + aEdit.SetText( OUString(rDefault) ); aEdit.SetSelection( Selection( SELECTION_MIN, SELECTION_MAX ) ); } @@ -109,7 +109,7 @@ void SvRTLInputBox::PositionPrompt(const String& rPrompt,const Size& rDlgSize) return; String aText_(convertLineEnd(rPrompt, LINEEND_CR)); aPromptText.SetPosPixel( LogicToPixel(Point(5,5))); - aPromptText.SetText( aText_ ); + aPromptText.SetText( OUString(aText_) ); Size aSize( rDlgSize ); aSize.Width() -= 70; aSize.Height() -= 50; @@ -131,7 +131,7 @@ IMPL_LINK_INLINE_START( SvRTLInputBox, CancelHdl, Button *, pButton ) { (void)pButton; - aText.Erase(); + aText=""; EndDialog( 0 ); return 0; } -- cgit 23.05'>distro/collabora/co-23.05 LibreOffice 核心代码仓库文档基金会
summaryrefslogtreecommitdiff
AgeCommit message (Expand)Author
2017-01-18tdf#102142 : Disable edit paragraph style in the print preview modeSzymon Kłos