summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2013-06-30 13:49:12 +0100
committerCaolán McNamara <caolanm@redhat.com>2013-06-30 20:40:15 +0100
commit0306e253fef4c25d4fe39ff9b5711c9487adc47b (patch)
tree10c71cd44b1d4899bd5b62495d13370df5993b4a
parentd70786a761025e7689a39d4026c8965d74962d4d (diff)
XubString->OUString
Change-Id: I40ff06facc304630ccedd82d2f20b3573bdc5cb4
-rw-r--r--include/vcl/btndlg.hxx8
-rw-r--r--include/vcl/svapp.hxx10
-rw-r--r--svx/source/dialog/prtqry.cxx2
-rw-r--r--sw/source/ui/shells/textsh1.cxx2
-rw-r--r--uui/source/alreadyopen.cxx4
-rw-r--r--uui/source/filechanged.cxx2
-rw-r--r--uui/source/openlocked.cxx4
-rw-r--r--uui/source/trylater.cxx4
-rw-r--r--vcl/inc/svdata.hxx2
-rw-r--r--vcl/source/app/svapp.cxx27
-rw-r--r--vcl/source/app/svmain.cxx2
-rw-r--r--vcl/source/window/btndlg.cxx8
12 files changed, 35 insertions, 40 deletions
diff --git a/include/vcl/btndlg.hxx b/include/vcl/btndlg.hxx
index 541109885079..12c7cbe394e1 100644
--- a/include/vcl/btndlg.hxx
+++ b/include/vcl/btndlg.hxx
@@ -84,14 +84,14 @@ public:
sal_uInt16 GetCurButtonId() const { return mnCurButtonId; }
- void AddButton( const XubString& rText, sal_uInt16 nId, sal_uInt16 nBtnFlags, long nSepPixel = 0 );
+ void AddButton( const OUString& rText, sal_uInt16 nId, sal_uInt16 nBtnFlags, long nSepPixel = 0 );
void AddButton( StandardButtonType eType, sal_uInt16 nId, sal_uInt16 nBtnFlags, long nSepPixel = 0 );
void RemoveButton( sal_uInt16 nId );
void Clear();
- sal_uInt16 GetButtonId( sal_uInt16 nButton ) const;
+ sal_uInt16 GetButtonId( sal_uInt16 nButton ) const;
PushButton* GetPushButton( sal_uInt16 nId ) const;
- void SetButtonText( sal_uInt16 nId, const XubString& rText );
- void SetButtonHelpText( sal_uInt16 nId, const XubString& rText );
+ void SetButtonText( sal_uInt16 nId, const OUString& rText );
+ void SetButtonHelpText( sal_uInt16 nId, const OUString& rText );
void SetFocusButton( sal_uInt16 nId = BUTTONDIALOG_BUTTON_NOTFOUND ) { mnFocusButtonId = nId; }
sal_uInt16 GetFocusButton() const { return mnFocusButtonId; }
diff --git a/include/vcl/svapp.hxx b/include/vcl/svapp.hxx
index c67a1890e7fd..67a48eee118a 100644
--- a/include/vcl/svapp.hxx
+++ b/include/vcl/svapp.hxx
@@ -143,12 +143,12 @@ public:
virtual void InitFinished();
virtual void DeInit();
- static sal_uInt16 GetCommandLineParamCount();
- static XubString GetCommandLineParam( sal_uInt16 nParam );
- static const XubString& GetAppFileName();
+ static sal_uInt16 GetCommandLineParamCount();
+ static OUString GetCommandLineParam( sal_uInt16 nParam );
+ static OUString GetAppFileName();
- virtual sal_uInt16 Exception( sal_uInt16 nError );
- static void Abort( const XubString& rErrorText );
+ virtual sal_uInt16 Exception( sal_uInt16 nError );
+ static void Abort( const OUString& rErrorText );
static void Execute();
static void Quit();
diff --git a/svx/source/dialog/prtqry.cxx b/svx/source/dialog/prtqry.cxx
index 520e5d7125bd..94b684dd8760 100644
--- a/svx/source/dialog/prtqry.cxx
+++ b/svx/source/dialog/prtqry.cxx
@@ -35,7 +35,7 @@ SvxPrtQryBox::SvxPrtQryBox(Window* pParent) :
AddButton(String(SVX_RES(RID_SVXSTR_QRY_PRINT_ALL)), 2, 0);
AddButton(BUTTON_CANCEL, RET_CANCEL, BUTTONDIALOG_CANCELBUTTON);
- SetButtonHelpText( RET_OK, String() );
+ SetButtonHelpText( RET_OK, OUString() );
}
SvxPrtQryBox::~SvxPrtQryBox()
diff --git a/sw/source/ui/shells/textsh1.cxx b/sw/source/ui/shells/textsh1.cxx
index 2ac65fd9f2a3..48e035552e4e 100644
--- a/sw/source/ui/shells/textsh1.cxx
+++ b/sw/source/ui/shells/textsh1.cxx
@@ -279,7 +279,7 @@ static short lcl_AskRedlineMode(Window *pWin)
aQBox.GetPushButton( RET_CANCEL )->SetHelpId(HID_AUTOFORMAT_REJECT );
aQBox.AddButton(String(SW_RES(STR_REDLINE_EDIT)), 2, 0);
aQBox.GetPushButton( 2 )->SetHelpId(HID_AUTOFORMAT_EDIT_CHG);
- aQBox.SetButtonHelpText( RET_OK, aEmptyStr );
+ aQBox.SetButtonHelpText( RET_OK, OUString() );
return aQBox.Execute();
}
diff --git a/uui/source/alreadyopen.cxx b/uui/source/alreadyopen.cxx
index 468cb43f1c17..002d05244542 100644
--- a/uui/source/alreadyopen.cxx
+++ b/uui/source/alreadyopen.cxx
@@ -42,8 +42,8 @@ AlreadyOpenQueryBox::AlreadyOpenQueryBox( Window* pParent, ResMgr* pResMgr, cons
AddButton( BUTTON_CANCEL, RET_CANCEL, BUTTONDIALOG_CANCELBUTTON );
}
- SetButtonHelpText( RET_YES, String::EmptyString() );
- SetButtonHelpText( RET_NO, String::EmptyString() );
+ SetButtonHelpText( RET_YES, OUString() );
+ SetButtonHelpText( RET_NO, OUString() );
}
AlreadyOpenQueryBox::~AlreadyOpenQueryBox()
diff --git a/uui/source/filechanged.cxx b/uui/source/filechanged.cxx
index 01217623a818..b8c1311a815a 100644
--- a/uui/source/filechanged.cxx
+++ b/uui/source/filechanged.cxx
@@ -31,7 +31,7 @@ FileChangedQueryBox::FileChangedQueryBox( Window* pParent, ResMgr* pResMgr ) :
BUTTONDIALOG_DEFBUTTON | BUTTONDIALOG_OKBUTTON | BUTTONDIALOG_FOCUSBUTTON);
AddButton( BUTTON_CANCEL, RET_CANCEL, BUTTONDIALOG_CANCELBUTTON );
- SetButtonHelpText( RET_YES, String::EmptyString() );
+ SetButtonHelpText( RET_YES, OUString() );
SetMessText(ResId(STR_FILECHANGED_MSG, *pResMgr).toString());
}
diff --git a/uui/source/openlocked.cxx b/uui/source/openlocked.cxx
index c40b4841586d..f58a871f79c1 100644
--- a/uui/source/openlocked.cxx
+++ b/uui/source/openlocked.cxx
@@ -33,8 +33,8 @@ OpenLockedQueryBox::OpenLockedQueryBox( Window* pParent, ResMgr* pResMgr, const
AddButton(ResId(STR_OPENLOCKED_OPENCOPY_BTN, *pResMgr).toString(), RET_NO, 0);
AddButton( BUTTON_CANCEL, RET_CANCEL, BUTTONDIALOG_CANCELBUTTON );
- SetButtonHelpText( RET_YES, String() );
- SetButtonHelpText( RET_NO, String() );
+ SetButtonHelpText( RET_YES, OUString() );
+ SetButtonHelpText( RET_NO, OUString() );
#ifdef WNT
// bnc#656566
diff --git a/uui/source/trylater.cxx b/uui/source/trylater.cxx
index 411ba0f8a5eb..57825c15ebe6 100644
--- a/uui/source/trylater.cxx
+++ b/uui/source/trylater.cxx
@@ -32,8 +32,8 @@ TryLaterQueryBox::TryLaterQueryBox( Window* pParent, ResMgr* pResMgr, const Stri
AddButton(ResId(STR_TRYLATER_SAVEAS_BTN, *pResMgr).toString(), RET_NO, 0);
AddButton( BUTTON_CANCEL, RET_CANCEL, BUTTONDIALOG_CANCELBUTTON );
- SetButtonHelpText( RET_YES, String::EmptyString() );
- SetButtonHelpText( RET_NO, String::EmptyString() );
+ SetButtonHelpText( RET_YES, OUString() );
+ SetButtonHelpText( RET_NO, OUString() );
}
TryLaterQueryBox::~TryLaterQueryBox()
diff --git a/vcl/inc/svdata.hxx b/vcl/inc/svdata.hxx
index a929165901a6..e0560316d453 100644
--- a/vcl/inc/svdata.hxx
+++ b/vcl/inc/svdata.hxx
@@ -117,7 +117,7 @@ struct ImplSVAppData
VclEventListeners* mpKeyListeners; // listeners for key events only (eg, extended toolkit)
ImplAccelManager* mpAccelMgr; // Accelerator Manager
XubString* mpAppName; // Application name
- XubString* mpAppFileName; // Abs. Application FileName
+ OUString* mpAppFileName; // Abs. Application FileName
OUString* mpDisplayName; // Application Display Name
String* mpFontPath; // Additional Fontpath
Help* mpHelp; // Application help
diff --git a/vcl/source/app/svapp.cxx b/vcl/source/app/svapp.cxx
index 8fdbfaa79458..0e4d763f0313 100644
--- a/vcl/source/app/svapp.cxx
+++ b/vcl/source/app/svapp.cxx
@@ -287,7 +287,7 @@ sal_uInt16 Application::GetCommandLineParamCount()
// -----------------------------------------------------------------------
-XubString Application::GetCommandLineParam( sal_uInt16 nParam )
+OUString Application::GetCommandLineParam( sal_uInt16 nParam )
{
OUString aParam;
osl_getCommandArg( nParam, &aParam.pData );
@@ -296,7 +296,7 @@ XubString Application::GetCommandLineParam( sal_uInt16 nParam )
// -----------------------------------------------------------------------
-const XubString& Application::GetAppFileName()
+OUString Application::GetAppFileName()
{
ImplSVData* pSVData = ImplGetSVData();
DBG_ASSERT( pSVData->maAppData.mpAppFileName, "AppFileName should be set to something after SVMain!" );
@@ -304,20 +304,15 @@ const XubString& Application::GetAppFileName()
return *pSVData->maAppData.mpAppFileName;
/*
- * #91147# provide a fallback for people without initialized
- * vcl here (like setup in responsefile mode)
+ * provide a fallback for people without initialized vcl here (like setup
+ * in responsefile mode)
*/
- static String aAppFileName;
- if( !aAppFileName.Len() )
- {
- OUString aExeFileName;
- osl_getExecutableFile( &aExeFileName.pData );
+ OUString aAppFileName;
+ OUString aExeFileName;
+ osl_getExecutableFile(&aExeFileName.pData);
- // convert path to native file format
- OUString aNativeFileName;
- osl::FileBase::getSystemPathFromFileURL( aExeFileName, aNativeFileName );
- aAppFileName = aNativeFileName;
- }
+ // convert path to native file format
+ osl::FileBase::getSystemPathFromFileURL(aExeFileName, aAppFileName);
return aAppFileName;
}
@@ -358,7 +353,7 @@ sal_uInt16 Application::Exception( sal_uInt16 nError )
// -----------------------------------------------------------------------
-void Application::Abort( const XubString& rErrorText )
+void Application::Abort( const OUString& rErrorText )
{
//HACK: Dump core iff --norestore command line argument is given (assuming
// this process is run by developers who are interested in cores, vs. end
@@ -366,7 +361,7 @@ void Application::Abort( const XubString& rErrorText )
bool dumpCore = false;
sal_uInt16 n = GetCommandLineParamCount();
for (sal_uInt16 i = 0; i != n; ++i) {
- if (GetCommandLineParam(i).EqualsAscii("--norestore")) {
+ if (GetCommandLineParam(i).equals("--norestore")) {
dumpCore = true;
break;
}
diff --git a/vcl/source/app/svmain.cxx b/vcl/source/app/svmain.cxx
index 9104be93aaa9..e2766b0c924a 100644
--- a/vcl/source/app/svmain.cxx
+++ b/vcl/source/app/svmain.cxx
@@ -289,7 +289,7 @@ bool InitVCL()
// convert path to native file format
OUString aNativeFileName;
osl::FileBase::getSystemPathFromFileURL( aExeFileName, aNativeFileName );
- pSVData->maAppData.mpAppFileName = new String( aNativeFileName );
+ pSVData->maAppData.mpAppFileName = new OUString( aNativeFileName );
// Initialize global data
pSVData->maGDIData.mpScreenFontList = new ImplDevFontList;
diff --git a/vcl/source/window/btndlg.cxx b/vcl/source/window/btndlg.cxx
index 5d96964706aa..02e338f236b5 100644
--- a/vcl/source/window/btndlg.cxx
+++ b/vcl/source/window/btndlg.cxx
@@ -262,7 +262,7 @@ void ButtonDialog::Click()
maClickHdl.Call( this );
}
-void ButtonDialog::AddButton( const XubString& rText, sal_uInt16 nId,
+void ButtonDialog::AddButton( const OUString& rText, sal_uInt16 nId,
sal_uInt16 nBtnFlags, long nSepPixel )
{
// PageItem anlegen
@@ -272,7 +272,7 @@ void ButtonDialog::AddButton( const XubString& rText, sal_uInt16 nId,
pItem->mnSepSize = nSepPixel;
pItem->mpPushButton = ImplCreatePushButton( nBtnFlags );
- if ( rText.Len() )
+ if (!rText.isEmpty())
pItem->mpPushButton->SetText( rText );
maItemList.push_back(pItem);
@@ -370,7 +370,7 @@ PushButton* ButtonDialog::GetPushButton( sal_uInt16 nId ) const
return NULL;
}
-void ButtonDialog::SetButtonText( sal_uInt16 nId, const XubString& rText )
+void ButtonDialog::SetButtonText( sal_uInt16 nId, const OUString& rText )
{
ImplBtnDlgItem* pItem = ImplGetItem( nId );
@@ -381,7 +381,7 @@ void ButtonDialog::SetButtonText( sal_uInt16 nId, const XubString& rText )
}
}
-void ButtonDialog::SetButtonHelpText( sal_uInt16 nId, const XubString& rText )
+void ButtonDialog::SetButtonHelpText( sal_uInt16 nId, const OUString& rText )
{
ImplBtnDlgItem* pItem = ImplGetItem( nId );