From 3e41fd078144094913ed62ae7fce5b91c820f98f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= Date: Sun, 22 Jan 2012 13:13:30 +0000 Subject: [PATCH] can replace all PLACEHOLDER_PATH tokens --- framework/source/services/autorecovery.cxx | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/framework/source/services/autorecovery.cxx b/framework/source/services/autorecovery.cxx index b464c1c6a02e..6d2b6b6314ea 100644 --- a/framework/source/services/autorecovery.cxx +++ b/framework/source/services/autorecovery.cxx @@ -81,9 +81,9 @@ #include #include #include +#include #include #include -#include #include #include #include @@ -3486,7 +3486,7 @@ void AutoRecovery::impl_showFullDiscError() rtl::OUString PLACEHOLDER_PATH(RTL_CONSTASCII_USTRINGPARAM("%PATH")); rtl::OUString sBtn(ResId::toString(FwkResId(STR_FULL_DISC_RETRY_BUTTON))); - String sMsg(ResId::toString(FwkResId(STR_FULL_DISC_MSG))); + rtl::OUString sMsg(ResId::toString(FwkResId(STR_FULL_DISC_MSG))); rtl::OUString sBackupURL(SvtPathOptions().GetBackupPath()); INetURLObject aConverter(sBackupURL); @@ -3494,9 +3494,8 @@ void AutoRecovery::impl_showFullDiscError() rtl::OUString sBackupPath = aConverter.getFSysPath(INetURLObject::FSYS_DETECT, &aDelimiter); if (sBackupPath.getLength() < 1) sBackupPath = sBackupURL; - sMsg.SearchAndReplace(PLACEHOLDER_PATH, sBackupPath); - ErrorBox dlgError(0, WB_OK, sMsg); + ErrorBox dlgError(0, WB_OK, comphelper::string::replace(sMsg, PLACEHOLDER_PATH, sBackupPath)); dlgError.SetButtonText(dlgError.GetButtonId(0), sBtn); dlgError.Execute(); }