diff options
author | Caolán McNamara <caolanm@redhat.com> | 2013-09-17 09:32:56 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-09-17 10:11:08 +0100 |
commit | 0cd21c2bedb2eacc3d0898046d43047bcc3ac1a9 (patch) | |
tree | aff9e2b018bc13a6a7385e2e7ed56631b2cbe759 | |
parent | f2be92b68d936c6e9d5e8a96deb1580bcbf8c17f (diff) |
drop intermediate Strings
Change-Id: I7f730d4f5329525eda9f78514dcaa3788149d077
-rw-r--r-- | desktop/source/app/app.cxx | 10 | ||||
-rw-r--r-- | desktop/source/deployment/gui/dp_gui_dialog2.cxx | 3 | ||||
-rw-r--r-- | desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx | 16 | ||||
-rw-r--r-- | framework/source/uielement/headermenucontroller.cxx | 2 | ||||
-rw-r--r-- | framework/source/uielement/langselectionmenucontroller.cxx | 6 | ||||
-rw-r--r-- | framework/source/uielement/toolbarsmenucontroller.cxx | 2 | ||||
-rw-r--r-- | svtools/source/uno/genericunodialog.cxx | 2 |
7 files changed, 20 insertions, 21 deletions
diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx index e4320e6de93d..70036d75abe2 100644 --- a/desktop/source/app/app.cxx +++ b/desktop/source/app/app.cxx @@ -363,7 +363,7 @@ OUString GetMsgString( { ResMgr* resMgr = Desktop::GetDesktopResManager(); if ( resMgr ) - return OUString( ResId( nId, *resMgr ) ); + return ResId(nId, *resMgr).toString(); } return aFallbackMsg; } @@ -391,7 +391,7 @@ OUString MakeStartupConfigAccessErrorMessage( OUString const & aInternalErrMsg ) ResMgr* pResMgr = Desktop::GetDesktopResManager(); if ( pResMgr ) - aDiagnosticMessage.append( OUString( ResId(STR_BOOTSTRAP_ERR_CFG_DATAACCESS, *pResMgr ) ) ); + aDiagnosticMessage.append( ResId(STR_BOOTSTRAP_ERR_CFG_DATAACCESS, *pResMgr).toString() ); else aDiagnosticMessage.appendAscii( "The program cannot be started." ); @@ -399,7 +399,7 @@ OUString MakeStartupConfigAccessErrorMessage( OUString const & aInternalErrMsg ) { aDiagnosticMessage.appendAscii( "\n\n" ); if ( pResMgr ) - aDiagnosticMessage.append( OUString( ResId(STR_INTERNAL_ERRMSG, *pResMgr ) ) ); + aDiagnosticMessage.append( ResId(STR_INTERNAL_ERRMSG, *pResMgr).toString() ); else aDiagnosticMessage.appendAscii( "The following internal error has occurred:\n\n" ); aDiagnosticMessage.append( aInternalErrMsg ); @@ -1169,7 +1169,7 @@ void restartOnMac(bool passArguments) { #if HAVE_FEATURE_MACOSX_SANDBOX (void) passArguments; // avoid warnings ResMgr *resMgr = Desktop::GetDesktopResManager(); - OUString aMessage = OUString( ResId( STR_LO_MUST_BE_RESTARTED, *resMgr ) ); + OUString aMessage = ResId(STR_LO_MUST_BE_RESTARTED, *resMgr).toString(); ErrorBox aRestartBox( NULL, WB_OK, aMessage ); aRestartBox.Execute(); @@ -1494,7 +1494,7 @@ int Desktop::Main() // create title string LanguageTag aLocale( LANGUAGE_SYSTEM); ResMgr* pLabelResMgr = ResMgr::SearchCreateResMgr( "ofa", aLocale ); - OUString aTitle = pLabelResMgr ? OUString( ResId( RID_APPTITLE, *pLabelResMgr ) ) : OUString(); + OUString aTitle = pLabelResMgr ? ResId(RID_APPTITLE, *pLabelResMgr).toString() : OUString(); delete pLabelResMgr; #ifdef DBG_UTIL diff --git a/desktop/source/deployment/gui/dp_gui_dialog2.cxx b/desktop/source/deployment/gui/dp_gui_dialog2.cxx index a653d1b6bbf5..6a90a9843529 100644 --- a/desktop/source/deployment/gui/dp_gui_dialog2.cxx +++ b/desktop/source/deployment/gui/dp_gui_dialog2.cxx @@ -96,8 +96,7 @@ struct StrAllFiles : public rtl::StaticWithInit< OUString, StrAllFiles > const SolarMutexGuard guard; ::std::auto_ptr< ResMgr > const resmgr( ResMgr::CreateResMgr( "fps_office" ) ); OSL_ASSERT( resmgr.get() != 0 ); - OUString ret( ResId( STR_FILTERNAME_ALL, *resmgr.get() ) ); - return ret; + return ResId(STR_FILTERNAME_ALL, *resmgr.get()).toString(); } }; diff --git a/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx b/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx index fa5db6987a5e..3c15ca386f65 100644 --- a/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx +++ b/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx @@ -217,14 +217,14 @@ UpdateInstallDialog::UpdateInstallDialog( m_bError(false), m_bNoEntry(true), m_bActivated(false), - m_sInstalling(OUString(DpGuiResId(RID_DLG_UPDATE_INSTALL_INSTALLING))), - m_sFinished(OUString(DpGuiResId(RID_DLG_UPDATE_INSTALL_FINISHED))), - m_sNoErrors(OUString(DpGuiResId(RID_DLG_UPDATE_INSTALL_NO_ERRORS))), - m_sErrorDownload(OUString(DpGuiResId(RID_DLG_UPDATE_INSTALL_ERROR_DOWNLOAD))), - m_sErrorInstallation(OUString(DpGuiResId(RID_DLG_UPDATE_INSTALL_ERROR_INSTALLATION))), - m_sErrorLicenseDeclined(OUString(DpGuiResId(RID_DLG_UPDATE_INSTALL_ERROR_LIC_DECLINED))), - m_sNoInstall(OUString(DpGuiResId(RID_DLG_UPDATE_INSTALL_EXTENSION_NOINSTALL))), - m_sThisErrorOccurred(OUString(DpGuiResId(RID_DLG_UPDATE_INSTALL_THIS_ERROR_OCCURRED))), + m_sInstalling(DPGUI_RESSTR(RID_DLG_UPDATE_INSTALL_INSTALLING)), + m_sFinished(DPGUI_RESSTR(RID_DLG_UPDATE_INSTALL_FINISHED)), + m_sNoErrors(DPGUI_RESSTR(RID_DLG_UPDATE_INSTALL_NO_ERRORS)), + m_sErrorDownload(DPGUI_RESSTR(RID_DLG_UPDATE_INSTALL_ERROR_DOWNLOAD)), + m_sErrorInstallation(DPGUI_RESSTR(RID_DLG_UPDATE_INSTALL_ERROR_INSTALLATION)), + m_sErrorLicenseDeclined(DPGUI_RESSTR(RID_DLG_UPDATE_INSTALL_ERROR_LIC_DECLINED)), + m_sNoInstall(DPGUI_RESSTR(RID_DLG_UPDATE_INSTALL_EXTENSION_NOINSTALL)), + m_sThisErrorOccurred(DPGUI_RESSTR(RID_DLG_UPDATE_INSTALL_THIS_ERROR_OCCURRED)), m_ft_action(this, DpGuiResId(RID_DLG_UPDATE_INSTALL_DOWNLOADING)), m_statusbar(this,DpGuiResId(RID_DLG_UPDATE_INSTALL_STATUSBAR)), m_ft_extension_name(this, DpGuiResId(RID_DLG_UPDATE_INSTALL_EXTENSION_NAME)), diff --git a/framework/source/uielement/headermenucontroller.cxx b/framework/source/uielement/headermenucontroller.cxx index 08485e35431e..1eb35521b17f 100644 --- a/framework/source/uielement/headermenucontroller.cxx +++ b/framework/source/uielement/headermenucontroller.cxx @@ -162,7 +162,7 @@ void HeaderMenuController::fillPopupMenu( const Reference< ::com::sun::star::fra if ( bAllOneState && ( nCount > 1 )) { // Insert special item for all command - pVCLPopupMenu->InsertItem( ALL_MENUITEM_ID, OUString( FwlResId( STR_MENU_HEADFOOTALL )), 0, OString(), 0 ); + pVCLPopupMenu->InsertItem( ALL_MENUITEM_ID, FwlResId(STR_MENU_HEADFOOTALL).toString(), 0, OString(), 0 ); OUStringBuffer aStrBuf( aCmd ); aStrBuf.appendAscii( "?On:bool=" ); diff --git a/framework/source/uielement/langselectionmenucontroller.cxx b/framework/source/uielement/langselectionmenucontroller.cxx index 5fd07ce5eb39..3c38e1945467 100644 --- a/framework/source/uielement/langselectionmenucontroller.cxx +++ b/framework/source/uielement/langselectionmenucontroller.cxx @@ -261,19 +261,19 @@ void LanguageSelectionMenuController::fillPopupMenu( Reference< css::awt::XPopup // entry for LANGUAGE_NONE ++nItemId; - pPopupMenu->InsertItem( nItemId, OUString(FwlResId( STR_LANGSTATUS_NONE )) ); + pPopupMenu->InsertItem( nItemId, FwlResId(STR_LANGSTATUS_NONE).toString() ); aCmd = aCmd_Language + "LANGUAGE_NONE"; pPopupMenu->SetItemCommand( nItemId, aCmd ); // entry for 'Reset to default language' ++nItemId; - pPopupMenu->InsertItem( nItemId, OUString(FwlResId( STR_RESET_TO_DEFAULT_LANGUAGE )) ); + pPopupMenu->InsertItem( nItemId, FwlResId(STR_RESET_TO_DEFAULT_LANGUAGE).toString() ); aCmd = aCmd_Language + "RESET_LANGUAGES"; pPopupMenu->SetItemCommand( nItemId, aCmd ); // entry for opening the Format/Character dialog ++nItemId; - pPopupMenu->InsertItem( nItemId, OUString(FwlResId( STR_LANGSTATUS_MORE ))); + pPopupMenu->InsertItem( nItemId, FwlResId(STR_LANGSTATUS_MORE).toString()); pPopupMenu->SetItemCommand( nItemId, aCmd_Dialog ); } diff --git a/framework/source/uielement/toolbarsmenucontroller.cxx b/framework/source/uielement/toolbarsmenucontroller.cxx index 423028d966f2..358d948fd3eb 100644 --- a/framework/source/uielement/toolbarsmenucontroller.cxx +++ b/framework/source/uielement/toolbarsmenucontroller.cxx @@ -519,7 +519,7 @@ void ToolbarsMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu >& r } } - OUString aLabelStr( FwkResId( STR_RESTORE_TOOLBARS )); + OUString aLabelStr(FWK_RESSTR(STR_RESTORE_TOOLBARS)); OUString aRestoreCmd( CMD_RESTOREVISIBILITY ); addCommand( m_xPopupMenu, aRestoreCmd, aLabelStr ); } diff --git a/svtools/source/uno/genericunodialog.cxx b/svtools/source/uno/genericunodialog.cxx index 5a222eed1206..22d4d52123f5 100644 --- a/svtools/source/uno/genericunodialog.cxx +++ b/svtools/source/uno/genericunodialog.cxx @@ -121,7 +121,7 @@ void OGenericUnoDialog::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, con m_bTitleAmbiguous = sal_False; if (m_pDialog) - m_pDialog->SetText(OUString(m_sTitle)); + m_pDialog->SetText(m_sTitle); } } |