diff options
author | Norbert Thiebaud <nthiebaud@gmail.com> | 2012-06-02 20:41:34 -0500 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2012-06-02 20:41:34 -0500 |
commit | eeac11421792819a42eb442ac4b64fa963901662 (patch) | |
tree | 9bac083d19480524daf57bade1dbf894d9837368 /framework | |
parent | 65269c97c305d7d8efc42add2faf99a18731af52 (diff) |
targeted string re-work
Change-Id: I3276836b76b69f04de38c2d36ae04b60c49d4873
Diffstat (limited to 'framework')
47 files changed, 339 insertions, 342 deletions
diff --git a/framework/source/accelerators/acceleratorconfiguration.cxx b/framework/source/accelerators/acceleratorconfiguration.cxx index 3fd5c72eac3b..19a7a0e3844a 100644 --- a/framework/source/accelerators/acceleratorconfiguration.cxx +++ b/framework/source/accelerators/acceleratorconfiguration.cxx @@ -178,13 +178,13 @@ void SAL_CALL XMLBasedAcceleratorConfiguration::setKeyEvent(const css::awt::KeyE (aKeyEvent.Modifiers == 0) ) throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Such key event seams not to be supported by any operating system.")), + ::rtl::OUString("Such key event seams not to be supported by any operating system."), static_cast< ::cppu::OWeakObject* >(this), 0); if (sCommand.isEmpty()) throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Empty command strings are not allowed here.")), + ::rtl::OUString("Empty command strings are not allowed here."), static_cast< ::cppu::OWeakObject* >(this), 1); @@ -224,7 +224,7 @@ css::uno::Sequence< css::awt::KeyEvent > SAL_CALL XMLBasedAcceleratorConfigurati { if (sCommand.isEmpty()) throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Empty command strings are not allowed here.")), + ::rtl::OUString("Empty command strings are not allowed here."), static_cast< ::cppu::OWeakObject* >(this), 1); @@ -261,7 +261,7 @@ css::uno::Sequence< css::uno::Any > SAL_CALL XMLBasedAcceleratorConfiguration::g const ::rtl::OUString& rCommand = lCommandList[i]; if (rCommand.isEmpty()) throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Empty command strings are not allowed here.")), + ::rtl::OUString("Empty command strings are not allowed here."), static_cast< ::cppu::OWeakObject* >(this), (sal_Int16)i); @@ -290,7 +290,7 @@ void SAL_CALL XMLBasedAcceleratorConfiguration::removeCommandFromAllKeyEvents(co { if (sCommand.isEmpty()) throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Empty command strings are not allowed here.")), + ::rtl::OUString("Empty command strings are not allowed here."), static_cast< ::cppu::OWeakObject* >(this), 0); @@ -300,7 +300,7 @@ void SAL_CALL XMLBasedAcceleratorConfiguration::removeCommandFromAllKeyEvents(co AcceleratorCache& rCache = impl_getCFG(sal_True); // sal_True => force getting of a writeable cache! if (!rCache.hasCommand(sCommand)) throw css::container::NoSuchElementException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Command does not exists inside this container.")), + ::rtl::OUString("Command does not exists inside this container."), static_cast< ::cppu::OWeakObject* >(this)); rCache.removeCommand(sCommand); @@ -331,7 +331,7 @@ void SAL_CALL XMLBasedAcceleratorConfiguration::reload() xIn = xStream->getInputStream(); if (!xIn.is()) throw css::io::IOException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Could not open accelerator configuration for reading.")), + ::rtl::OUString("Could not open accelerator configuration for reading."), static_cast< ::cppu::OWeakObject* >(this)); // impl_ts_load() does not clear the cache @@ -370,7 +370,7 @@ void SAL_CALL XMLBasedAcceleratorConfiguration::store() if (!xOut.is()) throw css::io::IOException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Could not open accelerator configuration for saving.")), + ::rtl::OUString("Could not open accelerator configuration for saving."), static_cast< ::cppu::OWeakObject* >(this)); impl_ts_save(xOut); @@ -397,7 +397,7 @@ void SAL_CALL XMLBasedAcceleratorConfiguration::storeToStorage(const css::uno::R if (!xOut.is()) throw css::io::IOException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Could not open accelerator configuration for saving.")), + ::rtl::OUString("Could not open accelerator configuration for saving."), static_cast< ::cppu::OWeakObject* >(this)); impl_ts_save(xOut); @@ -624,9 +624,9 @@ AcceleratorCache& XMLBasedAcceleratorConfiguration::impl_getCFG(sal_Bool bWriteA //----------------------------------------------- ::comphelper::Locale XMLBasedAcceleratorConfiguration::impl_ts_getLocale() const { - static ::rtl::OUString LOCALE_PACKAGE(RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Setup")); - static ::rtl::OUString LOCALE_PATH(RTL_CONSTASCII_USTRINGPARAM("L10N")); - static ::rtl::OUString LOCALE_KEY(RTL_CONSTASCII_USTRINGPARAM("ooLocale")); + static ::rtl::OUString LOCALE_PACKAGE("/org.openoffice.Setup"); + static ::rtl::OUString LOCALE_PATH("L10N"); + static ::rtl::OUString LOCALE_KEY("ooLocale"); // SAFE -> ---------------------------------- ReadGuard aReadLock(m_aLock); @@ -678,7 +678,7 @@ XCUBasedAcceleratorConfiguration::XCUBasedAcceleratorConfiguration(const css::un , m_pPrimaryWriteCache(0 ) , m_pSecondaryWriteCache(0 ) { - const ::rtl::OUString CFG_ENTRY_ACCELERATORS(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.Accelerators")); + const ::rtl::OUString CFG_ENTRY_ACCELERATORS("org.openoffice.Office.Accelerators"); m_xCfg = css::uno::Reference< css::container::XNameAccess > ( ::comphelper::ConfigurationHelper::openConfig( m_xSMGR, CFG_ENTRY_ACCELERATORS, ::comphelper::ConfigurationHelper::E_ALL_LOCALES ), css::uno::UNO_QUERY ); @@ -749,13 +749,13 @@ void SAL_CALL XCUBasedAcceleratorConfiguration::setKeyEvent(const css::awt::KeyE (aKeyEvent.Modifiers == 0) ) throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Such key event seams not to be supported by any operating system.")), + ::rtl::OUString("Such key event seams not to be supported by any operating system."), static_cast< ::cppu::OWeakObject* >(this), 0); if (sCommand.isEmpty()) throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Empty command strings are not allowed here.")), + ::rtl::OUString("Empty command strings are not allowed here."), static_cast< ::cppu::OWeakObject* >(this), 1); @@ -872,7 +872,7 @@ css::uno::Sequence< css::awt::KeyEvent > SAL_CALL XCUBasedAcceleratorConfigurati { if (sCommand.isEmpty()) throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Empty command strings are not allowed here.")), + ::rtl::OUString("Empty command strings are not allowed here."), static_cast< ::cppu::OWeakObject* >(this), 1); @@ -936,7 +936,7 @@ css::uno::Sequence< css::uno::Any > SAL_CALL XCUBasedAcceleratorConfiguration::g const ::rtl::OUString& rCommand = lCommandList[i]; if (rCommand.isEmpty()) throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Empty command strings are not allowed here.")), + ::rtl::OUString("Empty command strings are not allowed here."), static_cast< ::cppu::OWeakObject* >(this), (sal_Int16)i); @@ -969,7 +969,7 @@ void SAL_CALL XCUBasedAcceleratorConfiguration::removeCommandFromAllKeyEvents(co { if (sCommand.isEmpty()) throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Empty command strings are not allowed here.")), + ::rtl::OUString("Empty command strings are not allowed here."), static_cast< ::cppu::OWeakObject* >(this), 0); @@ -981,7 +981,7 @@ void SAL_CALL XCUBasedAcceleratorConfiguration::removeCommandFromAllKeyEvents(co if (!rPrimaryCache.hasCommand(sCommand) && !rSecondaryCache.hasCommand(sCommand)) throw css::container::NoSuchElementException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Command does not exists inside this container.")), + ::rtl::OUString("Command does not exists inside this container."), static_cast< ::cppu::OWeakObject* >(this)); if (rPrimaryCache.hasCommand(sCommand)) @@ -1073,17 +1073,17 @@ void SAL_CALL XCUBasedAcceleratorConfiguration::storeToStorage(const css::uno::R return; long nOpenModes = css::embed::ElementModes::READWRITE; - css::uno::Reference< css::embed::XStorage > xAcceleratorTypeStorage = xStorage->openStorageElement(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("accelerator")), nOpenModes); + css::uno::Reference< css::embed::XStorage > xAcceleratorTypeStorage = xStorage->openStorageElement(::rtl::OUString("accelerator"), nOpenModes); if (!xAcceleratorTypeStorage.is()) return; - css::uno::Reference< css::io::XStream > xStream = xAcceleratorTypeStorage->openStreamElement(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("current")), nOpenModes); + css::uno::Reference< css::io::XStream > xStream = xAcceleratorTypeStorage->openStreamElement(::rtl::OUString("current"), nOpenModes); css::uno::Reference< css::io::XOutputStream > xOut; if (xStream.is()) xOut = xStream->getOutputStream(); if (!xOut.is()) throw css::io::IOException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Could not open accelerator configuration for saving.")), + ::rtl::OUString("Could not open accelerator configuration for saving."), static_cast< ::cppu::OWeakObject* >(this)); // the original m_aCache has been split into primay cache and secondary cache... @@ -1282,7 +1282,7 @@ void XCUBasedAcceleratorConfiguration::impl_ts_load( sal_Bool bPreferred, const } const ::rtl::OUString sIsoLang = impl_ts_getLocale().toISO(); - const ::rtl::OUString sDefaultLocale(RTL_CONSTASCII_USTRINGPARAM("en-US")); + const ::rtl::OUString sDefaultLocale("en-US"); css::uno::Reference< css::container::XNameAccess > xKey; css::uno::Reference< css::container::XNameAccess > xCommand; @@ -1331,7 +1331,7 @@ void XCUBasedAcceleratorConfiguration::impl_ts_load( sal_Bool bPreferred, const sal_Int32 nIndex = 0; ::rtl::OUString sKeyCommand = sKey.getToken(0, '_', nIndex); - ::rtl::OUString sPrefix(RTL_CONSTASCII_USTRINGPARAM("KEY_")); + ::rtl::OUString sPrefix("KEY_"); aKeyEvent.KeyCode = m_rKeyMapping->mapIdentifierToCode(sPrefix + sKeyCommand); css::uno::Sequence< ::rtl::OUString > sToken(4); @@ -1566,7 +1566,7 @@ void XCUBasedAcceleratorConfiguration::reloadChanged( const ::rtl::OUString& sPr sal_Int32 nIndex = 0; sKeyIdentifier = sKey.getToken(0, '_', nIndex); - aKeyEvent.KeyCode = m_rKeyMapping->mapIdentifierToCode(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("KEY_"))+sKeyIdentifier); + aKeyEvent.KeyCode = m_rKeyMapping->mapIdentifierToCode(::rtl::OUString("KEY_")+sKeyIdentifier); css::uno::Sequence< ::rtl::OUString > sToken(3); const sal_Int32 nToken = 3; @@ -1666,9 +1666,9 @@ AcceleratorCache& XCUBasedAcceleratorConfiguration::impl_getCFG(sal_Bool bPrefer //----------------------------------------------- ::comphelper::Locale XCUBasedAcceleratorConfiguration::impl_ts_getLocale() const { - static ::rtl::OUString LOCALE_PACKAGE(RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Setup")); - static ::rtl::OUString LOCALE_PATH(RTL_CONSTASCII_USTRINGPARAM("L10N")); - static ::rtl::OUString LOCALE_KEY(RTL_CONSTASCII_USTRINGPARAM("ooLocale")); + static ::rtl::OUString LOCALE_PACKAGE("/org.openoffice.Setup"); + static ::rtl::OUString LOCALE_PATH("L10N"); + static ::rtl::OUString LOCALE_KEY("ooLocale"); // SAFE -> ---------------------------------- ReadGuard aReadLock(m_aLock); diff --git a/framework/source/accelerators/documentacceleratorconfiguration.cxx b/framework/source/accelerators/documentacceleratorconfiguration.cxx index c1434d47a3a0..6b13a72712a0 100644 --- a/framework/source/accelerators/documentacceleratorconfiguration.cxx +++ b/framework/source/accelerators/documentacceleratorconfiguration.cxx @@ -119,7 +119,7 @@ void SAL_CALL DocumentAcceleratorConfiguration::initialize(const css::uno::Seque ::comphelper::SequenceAsHashMap lArgs(lArguments); m_xDocumentRoot = lArgs.getUnpackedValueOrDefault( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DocumentRoot")), + ::rtl::OUString("DocumentRoot"), css::uno::Reference< css::embed::XStorage >()); aWriteLock.unlock(); diff --git a/framework/source/accelerators/moduleacceleratorconfiguration.cxx b/framework/source/accelerators/moduleacceleratorconfiguration.cxx index dcdb2a4a3e4e..b5117eaa7fdb 100644 --- a/framework/source/accelerators/moduleacceleratorconfiguration.cxx +++ b/framework/source/accelerators/moduleacceleratorconfiguration.cxx @@ -112,12 +112,12 @@ void SAL_CALL ModuleAcceleratorConfiguration::initialize(const css::uno::Sequenc WriteGuard aWriteLock(m_aLock); ::comphelper::SequenceAsHashMap lArgs(lArguments); - m_sModule = lArgs.getUnpackedValueOrDefault(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ModuleIdentifier")), ::rtl::OUString()); - m_sLocale = lArgs.getUnpackedValueOrDefault(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Locale")) , ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("x-default"))); + m_sModule = lArgs.getUnpackedValueOrDefault(::rtl::OUString("ModuleIdentifier"), ::rtl::OUString()); + m_sLocale = lArgs.getUnpackedValueOrDefault(::rtl::OUString("Locale") , ::rtl::OUString("x-default")); if (m_sModule.isEmpty()) throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("The module dependend accelerator configuration service was initialized with an empty module identifier!")), + ::rtl::OUString("The module dependend accelerator configuration service was initialized with an empty module identifier!"), static_cast< ::cppu::OWeakObject* >(this)); aWriteLock.unlock(); diff --git a/framework/source/accelerators/presethandler.cxx b/framework/source/accelerators/presethandler.cxx index b68fdc458d23..dd202afcb0e4 100644 --- a/framework/source/accelerators/presethandler.cxx +++ b/framework/source/accelerators/presethandler.cxx @@ -211,7 +211,7 @@ namespace { ::rtl::OUString lcl_getLocalizedMessage(::sal_Int32 nID) { - ::rtl::OUString sMessage(RTL_CONSTASCII_USTRINGPARAM("Unknown error.")); + ::rtl::OUString sMessage("Unknown error."); switch(nID) { @@ -242,8 +242,8 @@ void lcl_throwCorruptedUIConfigurationException( lcl_getLocalizedMessage(id), css::uno::Reference< css::uno::XInterface >(), (exception.getValueTypeName() + - rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(": \"")) + e.Message + - rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("\"")))); + rtl::OUString(": \"") + e.Message + + rtl::OUString("\""))); } } @@ -275,7 +275,7 @@ css::uno::Reference< css::embed::XStorage > PresetHandler::getOrCreateRootStorag // Note: May be an user uses URLs without a final slash! Check it ... nPos = sShareLayer.lastIndexOf('/'); if (nPos != sShareLayer.getLength()-1) - sShareLayer += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")); + sShareLayer += ::rtl::OUString("/"); sShareLayer += RELPATH_SHARE_LAYER; // folder /* @@ -330,7 +330,7 @@ css::uno::Reference< css::embed::XStorage > PresetHandler::getOrCreateRootStorag // Note: May be an user uses URLs without a final slash! Check it ... sal_Int32 nPos = sUserLayer.lastIndexOf('/'); if (nPos != sUserLayer.getLength()-1) - sUserLayer += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")); + sUserLayer += ::rtl::OUString("/"); sUserLayer += RELPATH_USER_LAYER; // storage file @@ -429,7 +429,7 @@ void PresetHandler::connectToResource( PresetHandler::EConfigType { if (!xDocumentRoot.is()) throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("There is valid root storage, where the UI configuration can work on.")), + ::rtl::OUString("There is valid root storage, where the UI configuration can work on."), css::uno::Reference< css::uno::XInterface >()); m_lDocumentStorages.setRootStorage(xDocumentRoot); xShare = xDocumentRoot; diff --git a/framework/source/classes/taskcreator.cxx b/framework/source/classes/taskcreator.cxx index 05aa9b44e5d3..52bc730e3758 100644 --- a/framework/source/classes/taskcreator.cxx +++ b/framework/source/classes/taskcreator.cxx @@ -103,9 +103,9 @@ TaskCreator::~TaskCreator() css::uno::Reference< css::frame::XFrame > TaskCreator::createTask( const ::rtl::OUString& sName , sal_Bool bVisible ) { - static ::rtl::OUString PACKAGE(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.TabBrowse")); - static ::rtl::OUString RELPATH(RTL_CONSTASCII_USTRINGPARAM("TaskCreatorService")); - static ::rtl::OUString KEY(RTL_CONSTASCII_USTRINGPARAM("ImplementationName")); + static ::rtl::OUString PACKAGE("org.openoffice.Office.TabBrowse"); + static ::rtl::OUString RELPATH("TaskCreatorService"); + static ::rtl::OUString KEY("ImplementationName"); /* SAFE { */ ReadGuard aReadLock( m_aLock ); diff --git a/framework/source/dispatch/dispatchinformationprovider.cxx b/framework/source/dispatch/dispatchinformationprovider.cxx index 7352b21e4c8e..91c003df14e5 100644 --- a/framework/source/dispatch/dispatchinformationprovider.cxx +++ b/framework/source/dispatch/dispatchinformationprovider.cxx @@ -171,7 +171,7 @@ css::uno::Sequence< css::uno::Reference< css::frame::XDispatchInformationProvide if (!xFrame.is()) return css::uno::Sequence< css::uno::Reference< css::frame::XDispatchInformationProvider > >(); - CloseDispatcher* pCloser = new CloseDispatcher(xSMGR, xFrame, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_self"))); // explicit "_self" ... not "" ... see implementation of close dispatcher itself! + CloseDispatcher* pCloser = new CloseDispatcher(xSMGR, xFrame, ::rtl::OUString("_self")); // explicit "_self" ... not "" ... see implementation of close dispatcher itself! css::uno::Reference< css::uno::XInterface > xCloser(static_cast< css::frame::XDispatch* >(pCloser), css::uno::UNO_QUERY); css::uno::Reference< css::frame::XDispatchInformationProvider > xCloseDispatch(xCloser , css::uno::UNO_QUERY); diff --git a/framework/source/dispatch/interceptionhelper.cxx b/framework/source/dispatch/interceptionhelper.cxx index 61523cf0bb86..4cb3987badfb 100644 --- a/framework/source/dispatch/interceptionhelper.cxx +++ b/framework/source/dispatch/interceptionhelper.cxx @@ -152,7 +152,7 @@ void SAL_CALL InterceptionHelper::registerDispatchProviderInterceptor(const css: else { aInfo.lURLPattern.realloc(1); - aInfo.lURLPattern[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("*")); + aInfo.lURLPattern[0] = ::rtl::OUString("*"); } // SAFE { diff --git a/framework/source/dispatch/oxt_handler.cxx b/framework/source/dispatch/oxt_handler.cxx index de5360724b44..ad3e493e9927 100644 --- a/framework/source/dispatch/oxt_handler.cxx +++ b/framework/source/dispatch/oxt_handler.cxx @@ -74,7 +74,7 @@ namespace framework{ // non exported definitions //_________________________________________________________________________________________________________________ -#define UNISTRING(s) rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(s)) +#define UNISTRING(s) rtl::OUString(s) //_________________________________________________________________________________________________________________ // declarations @@ -256,7 +256,7 @@ void SAL_CALL Oxt_Handler::dispatch( const css::util::URL& // I think we can the following ones: // a) look for given extension of url to map our type decision HARD CODED!!! // b) return preferred type every time... it's easy :-) - sTypeName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("oxt_OpenOffice_Extension")); + sTypeName = ::rtl::OUString("oxt_OpenOffice_Extension"); aDescriptor[::comphelper::MediaDescriptor::PROP_TYPENAME()] <<= sTypeName; aDescriptor >> lDescriptor; } diff --git a/framework/source/dispatch/windowcommanddispatch.cxx b/framework/source/dispatch/windowcommanddispatch.cxx index 022537c52f87..756a1661deba 100644 --- a/framework/source/dispatch/windowcommanddispatch.cxx +++ b/framework/source/dispatch/windowcommanddispatch.cxx @@ -151,11 +151,11 @@ IMPL_LINK(WindowCommandDispatch, impl_notifyCommand, void*, pParam) switch (nCommand) { case SHOWDIALOG_ID_PREFERENCES : - sCommand = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:OptionsTreeDialog")); + sCommand = rtl::OUString(".uno:OptionsTreeDialog"); break; case SHOWDIALOG_ID_ABOUT : - sCommand = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:About")); + sCommand = rtl::OUString(".uno:About"); break; default : diff --git a/framework/source/helper/oframes.cxx b/framework/source/helper/oframes.cxx index 8f518427b75a..963380122499 100644 --- a/framework/source/helper/oframes.cxx +++ b/framework/source/helper/oframes.cxx @@ -300,7 +300,7 @@ Any SAL_CALL OFrames::getByIndex( sal_Int32 nIndex ) throw( IndexOutOfBoundsExce sal_uInt32 nCount = m_pFrameContainer->getCount(); if ( nIndex < 0 || ( sal::static_int_cast< sal_uInt32 >( nIndex ) >= nCount )) - throw IndexOutOfBoundsException( OUString(RTL_CONSTASCII_USTRINGPARAM("OFrames::getByIndex - Index out of bounds")), + throw IndexOutOfBoundsException( OUString("OFrames::getByIndex - Index out of bounds"), (OWeakObject *)this ); // Set default return value. diff --git a/framework/source/helper/persistentwindowstate.cxx b/framework/source/helper/persistentwindowstate.cxx index e7ea0650dd23..74652f67ced8 100644 --- a/framework/source/helper/persistentwindowstate.cxx +++ b/framework/source/helper/persistentwindowstate.cxx @@ -227,9 +227,9 @@ void SAL_CALL PersistentWindowState::disposing(const css::lang::EventObject&) sRelPathBuf.append (sModuleName ); sRelPathBuf.appendAscii("\"]" ); - ::rtl::OUString sPackage(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Setup/")); + ::rtl::OUString sPackage("org.openoffice.Setup/"); ::rtl::OUString sRelPath = sRelPathBuf.makeStringAndClear(); - ::rtl::OUString sKey(RTL_CONSTASCII_USTRINGPARAM("ooSetupFactoryWindowAttributes")); + ::rtl::OUString sKey("ooSetupFactoryWindowAttributes"); try { @@ -257,9 +257,9 @@ void PersistentWindowState::implst_setWindowStateOnConfig(const css::uno::Refere sRelPathBuf.append (sModuleName ); sRelPathBuf.appendAscii("\"]" ); - ::rtl::OUString sPackage(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Setup/")); + ::rtl::OUString sPackage("org.openoffice.Setup/"); ::rtl::OUString sRelPath = sRelPathBuf.makeStringAndClear(); - ::rtl::OUString sKey(RTL_CONSTASCII_USTRINGPARAM("ooSetupFactoryWindowAttributes")); + ::rtl::OUString sKey("ooSetupFactoryWindowAttributes"); try { diff --git a/framework/source/helper/statusindicatorfactory.cxx b/framework/source/helper/statusindicatorfactory.cxx index 4c1e4149df83..7e0a9884f156 100644 --- a/framework/source/helper/statusindicatorfactory.cxx +++ b/framework/source/helper/statusindicatorfactory.cxx @@ -433,9 +433,9 @@ void StatusIndicatorFactory::implts_makeParentVisibleIfAllowed() bool bForceFrontAndFocus(false); ::comphelper::ConfigurationHelper::readDirectKey( xSMGR, - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.Common/View")), - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("NewDocumentHandling")), - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ForceFocusAndToFront")), + ::rtl::OUString("org.openoffice.Office.Common/View"), + ::rtl::OUString("NewDocumentHandling"), + ::rtl::OUString("ForceFocusAndToFront"), ::comphelper::ConfigurationHelper::E_READONLY) >>= bForceFrontAndFocus; pWindow->Show(sal_True, bForceFrontAndFocus ? SHOW_FOREGROUNDTASK : 0 ); diff --git a/framework/source/helper/titlebarupdate.cxx b/framework/source/helper/titlebarupdate.cxx index c14fd5814148..d8f2bd329c73 100644 --- a/framework/source/helper/titlebarupdate.cxx +++ b/framework/source/helper/titlebarupdate.cxx @@ -206,24 +206,24 @@ void TitleBarUpdate::impl_updateApplicationID(const css::uno::Reference< css::fr aModuleId.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.GlobalDocument")) || aModuleId.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.WebDocument")) || aModuleId.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.xforms.XMLFormDocument")) ) - sDesktopName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("writer")); + sDesktopName = ::rtl::OUString("writer"); else if ( aModuleId == "com.sun.star.sheet.SpreadsheetDocument" ) - sDesktopName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("calc")); + sDesktopName = ::rtl::OUString("calc"); else if ( aModuleId == "com.sun.star.presentation.PresentationDocument" ) - sDesktopName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("impress")); + sDesktopName = ::rtl::OUString("impress"); else if ( aModuleId == "com.sun.star.drawing.DrawingDocument" ) - sDesktopName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("draw")); + sDesktopName = ::rtl::OUString("draw"); else if ( aModuleId == "com.sun.star.formula.FormulaProperties" ) - sDesktopName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("math")); + sDesktopName = ::rtl::OUString("math"); else if ( aModuleId.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.sdb.DatabaseDocument")) || aModuleId.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.sdb.OfficeDatabaseDocument")) || aModuleId.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.sdb.RelationDesign")) || aModuleId.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.sdb.QueryDesign")) || aModuleId.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.sdb.TableDesign")) || aModuleId.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.sdb.DataSourceBrowser")) ) - sDesktopName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("base")); + sDesktopName = ::rtl::OUString("base"); else - sDesktopName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("startcenter")); + sDesktopName = ::rtl::OUString("startcenter"); sApplicationID = utl::ConfigManager::getProductName(). toAsciiLowerCase(); sApplicationID += ::rtl::OUString(sal_Unicode('-')); diff --git a/framework/source/helper/vclstatusindicator.cxx b/framework/source/helper/vclstatusindicator.cxx index a39f40569d9f..277e60f6061f 100644 --- a/framework/source/helper/vclstatusindicator.cxx +++ b/framework/source/helper/vclstatusindicator.cxx @@ -68,7 +68,7 @@ VCLStatusIndicator::VCLStatusIndicator(const css::uno::Reference< css::lang::XMu { if (!m_xParentWindow.is()) throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Cant work without a parent window!")), + ::rtl::OUString("Cant work without a parent window!"), static_cast< css::task::XStatusIndicator* >(this)); } diff --git a/framework/source/jobs/helponstartup.cxx b/framework/source/jobs/helponstartup.cxx index b1d0dab71803..d0bc8b225855 100644 --- a/framework/source/jobs/helponstartup.cxx +++ b/framework/source/jobs/helponstartup.cxx @@ -58,26 +58,26 @@ namespace framework{ // definitions // path to module config -static ::rtl::OUString CFG_PACKAGE_MODULES (RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Setup/Office/Factories")); -static ::rtl::OUString CFG_PACKAGE_SETUP (RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Setup")); -static ::rtl::OUString CFG_PACKAGE_COMMON (RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Office.Common")); -static ::rtl::OUString CFG_PATH_L10N (RTL_CONSTASCII_USTRINGPARAM("L10N")); -static ::rtl::OUString CFG_PATH_HELP (RTL_CONSTASCII_USTRINGPARAM("Help")); -static ::rtl::OUString CFG_KEY_LOCALE (RTL_CONSTASCII_USTRINGPARAM("ooLocale")); -static ::rtl::OUString CFG_KEY_HELPSYSTEM (RTL_CONSTASCII_USTRINGPARAM("System")); +static ::rtl::OUString CFG_PACKAGE_MODULES ("/org.openoffice.Setup/Office/Factories"); +static ::rtl::OUString CFG_PACKAGE_SETUP ("/org.openoffice.Setup"); +static ::rtl::OUString CFG_PACKAGE_COMMON ("/org.openoffice.Office.Common"); +static ::rtl::OUString CFG_PATH_L10N ("L10N"); +static ::rtl::OUString CFG_PATH_HELP ("Help"); +static ::rtl::OUString CFG_KEY_LOCALE ("ooLocale"); +static ::rtl::OUString CFG_KEY_HELPSYSTEM ("System"); // props of job environment -static ::rtl::OUString PROP_ENVIRONMENT (RTL_CONSTASCII_USTRINGPARAM("Environment")); -static ::rtl::OUString PROP_JOBCONFIG (RTL_CONSTASCII_USTRINGPARAM("JobConfig")); -static ::rtl::OUString PROP_ENVTYPE (RTL_CONSTASCII_USTRINGPARAM("EnvType")); -static ::rtl::OUString PROP_MODEL (RTL_CONSTASCII_USTRINGPARAM("Model")); +static ::rtl::OUString PROP_ENVIRONMENT ("Environment"); +static ::rtl::OUString PROP_JOBCONFIG ("JobConfig"); +static ::rtl::OUString PROP_ENVTYPE ("EnvType"); +static ::rtl::OUString PROP_MODEL ("Model"); // props of module config -static ::rtl::OUString PROP_HELP_BASEURL (RTL_CONSTASCII_USTRINGPARAM("ooSetupFactoryHelpBaseURL")); -static ::rtl::OUString PROP_AUTOMATIC_HELP (RTL_CONSTASCII_USTRINGPARAM("ooSetupFactoryHelpOnOpen")); +static ::rtl::OUString PROP_HELP_BASEURL ("ooSetupFactoryHelpBaseURL"); +static ::rtl::OUString PROP_AUTOMATIC_HELP ("ooSetupFactoryHelpOnOpen"); // special value of job environment -static ::rtl::OUString ENVTYPE_DOCUMENTEVENT (RTL_CONSTASCII_USTRINGPARAM("DOCUMENTEVENT")); +static ::rtl::OUString ENVTYPE_DOCUMENTEVENT ("DOCUMENTEVENT"); //----------------------------------------------- diff --git a/framework/source/jobs/jobdata.cxx b/framework/source/jobs/jobdata.cxx index bf1925a76bed..c1cbcf8d6112 100644 --- a/framework/source/jobs/jobdata.cxx +++ b/framework/source/jobs/jobdata.cxx @@ -425,15 +425,15 @@ JobData::EEnvironment JobData::getEnvironment() const switch(m_eEnvironment) { case E_EXECUTION : - sDescriptor = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("EXECUTOR")); + sDescriptor = ::rtl::OUString("EXECUTOR"); break; case E_DISPATCH : - sDescriptor = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DISPATCH")); + sDescriptor = ::rtl::OUString("DISPATCH"); break; case E_DOCUMENTEVENT : - sDescriptor = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DOCUMENTEVENT")); + sDescriptor = ::rtl::OUString("DOCUMENTEVENT"); break; default: break; @@ -583,7 +583,7 @@ sal_Bool isEnabled( const ::rtl::OUString& sAdminTime , we have to encode all '?' signs. Otherwhise e.g. "??-" will be translated to "~" ... */ - static ::rtl::OUString PATTERN_ISO8601(RTL_CONSTASCII_USTRINGPARAM("\?\?\?\?-\?\?-\?\?*\0")); + static ::rtl::OUString PATTERN_ISO8601("\?\?\?\?-\?\?-\?\?*\0"); WildCard aISOPattern(PATTERN_ISO8601); sal_Bool bValidAdmin = aISOPattern.Matches(sAdminTime); diff --git a/framework/source/jobs/shelljob.cxx b/framework/source/jobs/shelljob.cxx index b862893f22f7..9bf85711cf67 100644 --- a/framework/source/jobs/shelljob.cxx +++ b/framework/source/jobs/shelljob.cxx @@ -58,19 +58,19 @@ namespace framework{ // definitions /** address job configuration inside argument set provided on method execute(). */ -static const ::rtl::OUString PROP_JOBCONFIG(RTL_CONSTASCII_USTRINGPARAM("JobConfig")); +static const ::rtl::OUString PROP_JOBCONFIG("JobConfig"); /** address job configuration property "Command". */ -static const ::rtl::OUString PROP_COMMAND(RTL_CONSTASCII_USTRINGPARAM("Command")); +static const ::rtl::OUString PROP_COMMAND("Command"); /** address job configuration property "Arguments". */ -static const ::rtl::OUString PROP_ARGUMENTS(RTL_CONSTASCII_USTRINGPARAM("Arguments")); +static const ::rtl::OUString PROP_ARGUMENTS("Arguments"); /** address job configuration property "DeactivateJobIfDone". */ -static const ::rtl::OUString PROP_DEACTIVATEJOBIFDONE(RTL_CONSTASCII_USTRINGPARAM("DeactivateJobIfDone")); +static const ::rtl::OUString PROP_DEACTIVATEJOBIFDONE("DeactivateJobIfDone"); /** address job configuration property "CheckExitCode". */ -static const ::rtl::OUString PROP_CHECKEXITCODE(RTL_CONSTASCII_USTRINGPARAM("CheckExitCode")); +static const ::rtl::OUString PROP_CHECKEXITCODE("CheckExitCode"); //----------------------------------------------- diff --git a/framework/source/layoutmanager/layoutmanager.cxx b/framework/source/layoutmanager/layoutmanager.cxx index f0447a466738..e44e231cf0ce 100644 --- a/framework/source/layoutmanager/layoutmanager.cxx +++ b/framework/source/layoutmanager/layoutmanager.cxx @@ -144,24 +144,24 @@ LayoutManager::LayoutManager( const Reference< XMultiServiceFactory >& xServiceM , m_xPersistentWindowStateSupplier( Reference< XNameAccess >( xServiceManager->createInstance( SERVICENAME_WINDOWSTATECONFIGURATION ), UNO_QUERY )) , m_pGlobalSettings( 0 ) - , m_aStatusBarAlias( RTL_CONSTASCII_USTRINGPARAM( "private:resource/statusbar/statusbar" )) - , m_aProgressBarAlias( RTL_CONSTASCII_USTRINGPARAM( "private:resource/progressbar/progressbar" )) - , m_aPropDocked( RTL_CONSTASCII_USTRINGPARAM( WINDOWSTATE_PROPERTY_DOCKED )) - , m_aPropVisible( RTL_CONSTASCII_USTRINGPARAM( WINDOWSTATE_PROPERTY_VISIBLE )) - , m_aPropDockingArea( RTL_CONSTASCII_USTRINGPARAM( WINDOWSTATE_PROPERTY_DOCKINGAREA )) - , m_aPropDockPos( RTL_CONSTASCII_USTRINGPARAM( WINDOWSTATE_PROPERTY_DOCKPOS )) - , m_aPropPos( RTL_CONSTASCII_USTRINGPARAM( WINDOWSTATE_PROPERTY_POS )) - , m_aPropSize( RTL_CONSTASCII_USTRINGPARAM( WINDOWSTATE_PROPERTY_SIZE )) - , m_aPropUIName( RTL_CONSTASCII_USTRINGPARAM( WINDOWSTATE_PROPERTY_UINAME )) - , m_aPropStyle( RTL_CONSTASCII_USTRINGPARAM( WINDOWSTATE_PROPERTY_STYLE )) - , m_aPropLocked( RTL_CONSTASCII_USTRINGPARAM( WINDOWSTATE_PROPERTY_LOCKED )) - , m_aCustomizeCmd( RTL_CONSTASCII_USTRINGPARAM( "ConfigureDialog" )) + , m_aStatusBarAlias( "private:resource/statusbar/statusbar" ) + , m_aProgressBarAlias( "private:resource/progressbar/progressbar" ) + , m_aPropDocked( WINDOWSTATE_PROPERTY_DOCKED ) + , m_aPropVisible( WINDOWSTATE_PROPERTY_VISIBLE ) + , m_aPropDockingArea( WINDOWSTATE_PROPERTY_DOCKINGAREA ) + , m_aPropDockPos( WINDOWSTATE_PROPERTY_DOCKPOS ) + , m_aPropPos( WINDOWSTATE_PROPERTY_POS ) + , m_aPropSize( WINDOWSTATE_PROPERTY_SIZE ) + , m_aPropUIName( WINDOWSTATE_PROPERTY_UINAME ) + , m_aPropStyle( WINDOWSTATE_PROPERTY_STYLE ) + , m_aPropLocked( WINDOWSTATE_PROPERTY_LOCKED ) + , m_aCustomizeCmd( "ConfigureDialog" ) , m_aListenerContainer( m_aLock.getShareableOslMutex() ) , m_pToolbarManager( 0 ) { // Initialize statusbar member const sal_Bool bRefreshVisibility = sal_False; - m_aStatusBarElement.m_aType = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "statusbar" )); + m_aStatusBarElement.m_aType = rtl::OUString( "statusbar" ); m_aStatusBarElement.m_aName = m_aStatusBarAlias; m_pToolbarManager = new ToolbarLayoutManager( xServiceManager, m_xUIElementFactoryManager, this ); @@ -212,7 +212,7 @@ void LayoutManager::impl_clearUpMenuBar() { try { - xPropSet->getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "XMenuBar" ))) >>= xMenuBar; + xPropSet->getPropertyValue( ::rtl::OUString( "XMenuBar" )) >>= xMenuBar; } catch (const beans::UnknownPropertyException&) { @@ -652,7 +652,7 @@ void LayoutManager::implts_writeWindowStateData( const rtl::OUString& aName, con try { // Check persistent flag of the user interface element - xPropSet->getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Persistent" ))) >>= bPersistent; + xPropSet->getPropertyValue( ::rtl::OUString( "Persistent" )) >>= bPersistent; } catch (const beans::UnknownPropertyException&) { @@ -733,9 +733,9 @@ Reference< XUIElement > LayoutManager::implts_createElement( const rtl::OUString ReadGuard aReadLock( m_aLock ); Sequence< PropertyValue > aPropSeq( 2 ); - aPropSeq[0].Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Frame" )); + aPropSeq[0].Name = ::rtl::OUString( "Frame" ); aPropSeq[0].Value <<= m_xFrame; - aPropSeq[1].Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Persistent" )); + aPropSeq[1].Name = ::rtl::OUString( "Persistent" ); aPropSeq[1].Value <<= sal_True; try @@ -1514,7 +1514,7 @@ throw (RuntimeException) { try { - xPropSet->getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "XMenuBar" ))) >>= xMenuBar; + xPropSet->getPropertyValue( ::rtl::OUString( "XMenuBar" )) >>= xMenuBar; } catch (const beans::UnknownPropertyException&) { @@ -2492,7 +2492,7 @@ sal_Bool LayoutManager::implts_resizeContainerWindow( const awt::Size& rContaine { sal_Int32 nDisplay = xContainerTopWindow->getDisplay(); Reference< beans::XPropertySet > xDisplayInfo( xDisplayAccess->getByIndex( nDisplay ), UNO_QUERY_THROW ); - OSL_VERIFY( xDisplayInfo->getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "WorkArea" ) ) ) >>= aWorkArea ); + OSL_VERIFY( xDisplayInfo->getPropertyValue( ::rtl::OUString( "WorkArea" ) ) >>= aWorkArea ); } catch( const Exception& ) { @@ -2676,8 +2676,8 @@ IMPL_LINK_NOARG(LayoutManager, MenuBarClose) xDispatcher->executeDispatch( xProvider, - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:CloseWin")), - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_self")), + ::rtl::OUString(".uno:CloseWin"), + ::rtl::OUString("_self"), 0, uno::Sequence< beans::PropertyValue >()); @@ -3024,7 +3024,7 @@ void SAL_CALL LayoutManager::elementInserted( const ui::ConfigurationEvent& Even Reference< XUIElementSettings > xElementSettings( xUIElement, UNO_QUERY ); if ( xElementSettings.is() ) { - ::rtl::OUString aConfigSourcePropName( RTL_CONSTASCII_USTRINGPARAM( "ConfigurationSource" )); + ::rtl::OUString aConfigSourcePropName( "ConfigurationSource" ); uno::Reference< XPropertySet > xPropSet( xElementSettings, uno::UNO_QUERY ); if ( xPropSet.is() ) { @@ -3074,7 +3074,7 @@ void SAL_CALL LayoutManager::elementRemoved( const ui::ConfigurationEvent& Event if ( xElementSettings.is() ) { bool bNoSettings( false ); - ::rtl::OUString aConfigSourcePropName( RTL_CONSTASCII_USTRINGPARAM( "ConfigurationSource" )); + ::rtl::OUString aConfigSourcePropName( "ConfigurationSource" ); Reference< XInterface > xElementCfgMgr; Reference< XPropertySet > xPropSet( xElementSettings, UNO_QUERY ); @@ -3157,7 +3157,7 @@ void SAL_CALL LayoutManager::elementReplaced( const ui::ConfigurationEvent& Even Reference< XUIElementSettings > xElementSettings( xUIElement, UNO_QUERY ); if ( xElementSettings.is() ) { - ::rtl::OUString aConfigSourcePropName( RTL_CONSTASCII_USTRINGPARAM( "ConfigurationSource" )); + ::rtl::OUString aConfigSourcePropName( "ConfigurationSource" ); Reference< XInterface > xElementCfgMgr; Reference< XPropertySet > xPropSet( xElementSettings, UNO_QUERY ); diff --git a/framework/source/loadenv/loadenv.cxx b/framework/source/loadenv/loadenv.cxx index ea4b4bb00b2d..cc24ece023ea 100644 --- a/framework/source/loadenv/loadenv.cxx +++ b/framework/source/loadenv/loadenv.cxx @@ -192,7 +192,7 @@ css::uno::Reference< css::lang::XComponent > LoadEnv::loadComponentFromURL(const { case LoadEnvException::ID_INVALID_MEDIADESCRIPTOR: throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Optional list of arguments seem to be corrupted.")), + ::rtl::OUString("Optional list of arguments seem to be corrupted."), xLoader, 4); @@ -782,8 +782,8 @@ LoadEnv::EContentType LoadEnv::classifyContent(const ::rtl::OUString& void LoadEnv::impl_detectTypeAndFilter() throw(LoadEnvException, css::uno::RuntimeException) { - static ::rtl::OUString TYPEPROP_PREFERREDFILTER(RTL_CONSTASCII_USTRINGPARAM("PreferredFilter")); - static ::rtl::OUString FILTERPROP_FLAGS (RTL_CONSTASCII_USTRINGPARAM("Flags")); + static ::rtl::OUString TYPEPROP_PREFERREDFILTER("PreferredFilter"); + static ::rtl::OUString FILTERPROP_FLAGS ("Flags"); static sal_Int32 FILTERFLAG_TEMPLATEPATH = 16; // SAFE -> @@ -966,9 +966,9 @@ sal_Bool LoadEnv::impl_furtherDocsAllowed() { css::uno::Any aVal = ::comphelper::ConfigurationHelper::readDirectKey( xSMGR, - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.Common/")), - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Misc")), - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("MaxOpenDocuments")), + ::rtl::OUString("org.openoffice.Office.Common/"), + ::rtl::OUString("Misc"), + ::rtl::OUString("MaxOpenDocuments"), ::comphelper::ConfigurationHelper::E_READONLY); // NIL means: count of allowed documents = infinite ! @@ -1258,7 +1258,7 @@ void LoadEnv::impl_jumpToMark(const css::uno::Reference< css::frame::XFrame >& x // <- SAFE css::util::URL aCmd; - aCmd.Complete = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:JumpToMark")); + aCmd.Complete = ::rtl::OUString(".uno:JumpToMark"); css::uno::Reference< css::util::XURLTransformer > xParser(xSMGR->createInstance(SERVICENAME_URLTRANSFORMER), css::uno::UNO_QUERY_THROW); xParser->parseStrict(aCmd); @@ -1268,7 +1268,7 @@ void LoadEnv::impl_jumpToMark(const css::uno::Reference< css::frame::XFrame >& x return; ::comphelper::SequenceAsHashMap lArgs; - lArgs[::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Bookmark"))] <<= aURL.Mark; + lArgs[::rtl::OUString("Bookmark")] <<= aURL.Mark; xDispatcher->dispatch(aCmd, lArgs.getAsConstPropertyValueList()); } @@ -1707,9 +1707,9 @@ void LoadEnv::impl_makeFrameWindowVisible(const css::uno::Reference< css::awt::X css::uno::Any const a = ::comphelper::ConfigurationHelper::readDirectKey( xSMGR, - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.Common/View")), - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("NewDocumentHandling")), - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ForceFocusAndToFront")), + ::rtl::OUString("org.openoffice.Office.Common/View"), + ::rtl::OUString("NewDocumentHandling"), + ::rtl::OUString("ForceFocusAndToFront"), ::comphelper::ConfigurationHelper::E_READONLY); a >>= bForceFrontAndFocus; } @@ -1724,7 +1724,7 @@ void LoadEnv::impl_makeFrameWindowVisible(const css::uno::Reference< css::awt::X void LoadEnv::impl_applyPersistentWindowState(const css::uno::Reference< css::awt::XWindow >& xWindow) { - static ::rtl::OUString PACKAGE_SETUP_MODULES(RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Setup/Office/Factories")); + static ::rtl::OUString PACKAGE_SETUP_MODULES("/org.openoffice.Setup/Office/Factories"); // no window -> action not possible if (!xWindow.is()) diff --git a/framework/source/recording/dispatchrecorder.cxx b/framework/source/recording/dispatchrecorder.cxx index 9d398a05140c..b061da596aaa 100644 --- a/framework/source/recording/dispatchrecorder.cxx +++ b/framework/source/recording/dispatchrecorder.cxx @@ -104,7 +104,7 @@ Sequence< Any > make_seq_out_of_struct( { throw RuntimeException( type.getTypeName() + - ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("is no struct or exception!") ), + ::rtl::OUString( "is no struct or exception!" ), Reference< XInterface >() ); } typelib_TypeDescription * pTD = 0; @@ -113,7 +113,7 @@ Sequence< Any > make_seq_out_of_struct( if (! pTD) { throw RuntimeException( - ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("cannot get type descr of type ") ) + + ::rtl::OUString( "cannot get type descr of type " ) + type.getTypeName(), Reference< XInterface >() ); } @@ -130,7 +130,7 @@ DispatchRecorder::DispatchRecorder( const css::uno::Reference< css::lang::XMulti : ThreadHelpBase ( &Application::GetSolarMutex() ) , ::cppu::OWeakObject( ) , m_xSMGR ( xSMGR ) - , m_xConverter( m_xSMGR->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.script.Converter"))), css::uno::UNO_QUERY ) + , m_xConverter( m_xSMGR->createInstance(::rtl::OUString("com.sun.star.script.Converter")), css::uno::UNO_QUERY ) { } @@ -343,7 +343,7 @@ void SAL_CALL DispatchRecorder::implts_recordMacro( const ::rtl::OUString& aURL, ::rtl::OUStringBuffer aArgumentBuffer(1000); ::rtl::OUString sArrayName; // this value is used to name the arrays of aArgumentBuffer - sArrayName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("args")); + sArrayName = ::rtl::OUString("args"); sArrayName += ::rtl::OUString::valueOf((sal_Int32)m_nRecordingID); aScriptBuffer.appendAscii("rem ----------------------------------------------------------------------\n"); @@ -445,8 +445,7 @@ com::sun::star::uno::Any SAL_CALL DispatchRecorder::getByIndex(sal_Int32 idx) t { if (idx >= (sal_Int32)m_aStatements.size()) { throw com::sun::star::lang::IndexOutOfBoundsException( - ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( - "Dispatch recorder out of bounds") ), + ::rtl::OUString( "Dispatch recorder out of bounds" ), Reference< XInterface >() ); } @@ -462,15 +461,13 @@ void SAL_CALL DispatchRecorder::replaceByIndex(sal_Int32 idx, const com::sun::st if (element.getValueType() != ::getCppuType((const com::sun::star::frame::DispatchStatement *)NULL)) { throw com::sun::star::lang::IllegalArgumentException( - ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( - "Illegal argument in dispatch recorder") ), + ::rtl::OUString( "Illegal argument in dispatch recorder" ), Reference< XInterface >(), 2 ); } if (idx >= (sal_Int32)m_aStatements.size()) { throw com::sun::star::lang::IndexOutOfBoundsException( - ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( - "Dispatch recorder out of bounds") ), + ::rtl::OUString( "Dispatch recorder out of bounds" ), Reference< XInterface >() ); } diff --git a/framework/source/services/backingcomp.cxx b/framework/source/services/backingcomp.cxx index 619bfdb40739..a3032843f89d 100644 --- a/framework/source/services/backingcomp.cxx +++ b/framework/source/services/backingcomp.cxx @@ -457,17 +457,17 @@ void SAL_CALL BackingComp::attachFrame( /*IN*/ const css::uno::Reference< css::f // check some required states if (m_xFrame.is()) throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("already attached")), + ::rtl::OUString("already attached"), static_cast< ::cppu::OWeakObject* >(this)); if (!xFrame.is()) throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("invalid frame reference")), + ::rtl::OUString("invalid frame reference"), static_cast< ::cppu::OWeakObject* >(this)); if (!m_xWindow.is()) throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("instance seams to be not or wrong initialized")), + ::rtl::OUString("instance seams to be not or wrong initialized"), static_cast< ::cppu::OWeakObject* >(this)); // safe the frame reference @@ -653,7 +653,7 @@ void SAL_CALL BackingComp::disposing( /*IN*/ const css::lang::EventObject& aEven if (!aEvent.Source.is() || aEvent.Source!=m_xWindow || !m_xWindow.is()) throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("unexpected source or called twice")), + ::rtl::OUString("unexpected source or called twice"), static_cast< ::cppu::OWeakObject* >(this)); m_xWindow = css::uno::Reference< css::awt::XWindow >(); @@ -747,7 +747,7 @@ void SAL_CALL BackingComp::addEventListener( /*IN*/ const css::uno::Reference< c throw(css::uno::RuntimeException) { throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("not supported")), + ::rtl::OUString("not supported"), static_cast< ::cppu::OWeakObject* >(this)); } @@ -794,7 +794,7 @@ void SAL_CALL BackingComp::initialize( /*IN*/ const css::uno::Sequence< css::uno if (m_xWindow.is()) throw css::uno::Exception( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("already initialized")), + ::rtl::OUString("already initialized"), static_cast< ::cppu::OWeakObject* >(this)); css::uno::Reference< css::awt::XWindow > xParentWindow; @@ -805,7 +805,7 @@ void SAL_CALL BackingComp::initialize( /*IN*/ const css::uno::Sequence< css::uno ) { throw css::uno::Exception( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("wrong or corrupt argument list")), + ::rtl::OUString("wrong or corrupt argument list"), static_cast< ::cppu::OWeakObject* >(this)); } @@ -816,7 +816,7 @@ void SAL_CALL BackingComp::initialize( /*IN*/ const css::uno::Sequence< css::uno if (!m_xWindow.is()) throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("couldn't create component window")), + ::rtl::OUString("couldn't create component window"), static_cast< ::cppu::OWeakObject* >(this)); // start listening for window disposing diff --git a/framework/source/services/backingwindow.cxx b/framework/source/services/backingwindow.cxx index 811e47c730c5..92b0b7fff33c 100644 --- a/framework/source/services/backingwindow.cxx +++ b/framework/source/services/backingwindow.cxx @@ -166,16 +166,16 @@ BackingWindow::BackingWindow( Window* i_pParent ) : { Sequence<Any> args(1); PropertyValue val( - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("nodepath") ), + rtl::OUString( "nodepath" ), 0, - Any(rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Office.Common/Help/StartCenter"))), + Any(rtl::OUString( "/org.openoffice.Office.Common/Help/StartCenter")), PropertyState_DIRECT_VALUE); args.getArray()[0] <<= val; Reference<container::XNameAccess> xNameAccess(xConfig->createInstanceWithArguments(SERVICENAME_CFGREADACCESS,args), UNO_QUERY); if( xNameAccess.is() ) { //throws css::container::NoSuchElementException, css::lang::WrappedTargetException - Any value( xNameAccess->getByName(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("StartCenterHideExternalLinks"))) ); + Any value( xNameAccess->getByName(rtl::OUString("StartCenterHideExternalLinks")) ); mnHideExternalLinks = value.get<sal_Int32>(); } } @@ -202,19 +202,19 @@ BackingWindow::BackingWindow( Window* i_pParent ) : maToolbox.InsertItem( nItemId_TplRep, Image() ); maToolbox.SetItemText( nItemId_TplRep, aTplRepHelpText ); maToolbox.SetQuickHelpText( nItemId_TplRep, aTplRepHelpText ); - maToolbox.SetItemCommand( nItemId_TplRep, String( RTL_CONSTASCII_USTRINGPARAM( ".HelpId:StartCenter:TemplateRepository" ) ) ); + maToolbox.SetItemCommand( nItemId_TplRep, String( ".HelpId:StartCenter:TemplateRepository" ) ); maToolbox.ShowItem( nItemId_TplRep ); maToolbox.InsertItem( nItemId_Extensions, Image() ); maToolbox.SetQuickHelpText( nItemId_Extensions, aExtHelpText ); maToolbox.SetItemText( nItemId_Extensions, aExtHelpText ); - maToolbox.SetItemCommand( nItemId_Extensions, String( RTL_CONSTASCII_USTRINGPARAM( ".HelpId:StartCenter:Extensions" ) ) ); + maToolbox.SetItemCommand( nItemId_Extensions, String( ".HelpId:StartCenter:Extensions" ) ); maToolbox.ShowItem( nItemId_Extensions ); maToolbox.InsertItem( nItemId_Info, Image() ); maToolbox.SetItemText( nItemId_Info, aInfoHelpText ); maToolbox.SetQuickHelpText( nItemId_Info, aInfoHelpText ); - maToolbox.SetItemCommand( nItemId_Info, String( RTL_CONSTASCII_USTRINGPARAM( ".HelpId:StartCenter:Info" ) ) ); + maToolbox.SetItemCommand( nItemId_Info, String( ".HelpId:StartCenter:Info" ) ); maToolbox.ShowItem( nItemId_Info ); // get dispatch provider @@ -326,24 +326,24 @@ void BackingWindow::prepareRecentFileMenu() rArgsList.realloc( nArgs ); nArgs--; - rArgsList[nArgs].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FilterName" )); + rArgsList[nArgs].Name = rtl::OUString( "FilterName" ); rArgsList[nArgs].Value = makeAny( aFilter ); if( !aFilterOpt.isEmpty() ) { nArgs--; - rArgsList[nArgs].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FilterOptions" )); + rArgsList[nArgs].Name = rtl::OUString( "FilterOptions" ); rArgsList[nArgs].Value = makeAny( aFilterOpt ); } // documents in the picklist will never be opened as templates nArgs--; - rArgsList[nArgs].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "AsTemplate" )); + rArgsList[nArgs].Name = rtl::OUString( "AsTemplate" ); rArgsList[nArgs].Value = makeAny( (sal_Bool) sal_False ); nArgs--; - rArgsList[nArgs].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Referer" )); - rArgsList[nArgs].Value = makeAny( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "private:user" ) ) ); + rArgsList[nArgs].Name = rtl::OUString( "Referer" ); + rArgsList[nArgs].Value = makeAny( rtl::OUString( "private:user" ) ); // and finally create an entry in the popupmenu rtl::OUString aMenuTitle; @@ -474,7 +474,7 @@ void BackingWindow::initControls() std::set< rtl::OUString > aFileNewAppsAvailable; SvtDynamicMenuOptions aOpt; Sequence < Sequence < PropertyValue > > aNewMenu = aOpt.GetMenu( E_NEWMENU ); - const rtl::OUString sURLKey( RTL_CONSTASCII_USTRINGPARAM( "URL" ) ); + const rtl::OUString sURLKey( "URL" ); const Sequence< PropertyValue >* pNewMenu = aNewMenu.getConstArray(); const Sequence< PropertyValue >* pNewMenuEnd = aNewMenu.getConstArray() + aNewMenu.getLength(); @@ -861,7 +861,7 @@ IMPL_LINK_NOARG(BackingWindow, ToolboxHdl) { Sequence<Any> args(1); PropertyValue val( - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("nodepath") ), + rtl::OUString( "nodepath" ), 0, Any(rtl::OUString::createFromAscii(pNodePath)), PropertyState_DIRECT_VALUE); @@ -877,7 +877,7 @@ IMPL_LINK_NOARG(BackingWindow, ToolboxHdl) Reference< com::sun::star::system::XSystemShellExecute > xSystemShellExecute( comphelper::getProcessServiceFactory()->createInstance( - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.system.SystemShellExecute" ) ) ), + rtl::OUString( "com.sun.star.system.SystemShellExecute" ) ), UNO_QUERY_THROW); //throws css::lang::IllegalArgumentException, css::system::SystemShellExecuteException xSystemShellExecute->execute( sURL, rtl::OUString(), com::sun::star::system::SystemShellExecuteFlags::URIS_ONLY); @@ -896,27 +896,27 @@ IMPL_LINK( BackingWindow, ClickHdl, Button*, pButton ) { // dispatch the appropriate URL and end the dialog if( pButton == &maWriterButton ) - dispatchURL( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(WRITER_URL) ) ); + dispatchURL( rtl::OUString( WRITER_URL ) ); else if( pButton == &maCalcButton ) - dispatchURL( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(CALC_URL) ) ); + dispatchURL( rtl::OUString( CALC_URL ) ); else if( pButton == &maImpressButton ) - dispatchURL( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(IMPRESS_WIZARD_URL) ) ); + dispatchURL( rtl::OUString( IMPRESS_WIZARD_URL ) ); else if( pButton == &maDrawButton ) - dispatchURL( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(DRAW_URL) ) ); + dispatchURL( rtl::OUString( DRAW_URL ) ); else if( pButton == &maDBButton ) - dispatchURL( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(BASE_URL) ) ); + dispatchURL( rtl::OUString( BASE_URL ) ); else if( pButton == &maMathButton ) - dispatchURL( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(MATH_URL) ) ); + dispatchURL( rtl::OUString( MATH_URL ) ); else if( pButton == &maOpenButton ) { Reference< XDispatchProvider > xFrame( mxFrame, UNO_QUERY ); Sequence< com::sun::star::beans::PropertyValue > aArgs(1); PropertyValue* pArg = aArgs.getArray(); - pArg[0].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Referer")); - pArg[0].Value <<= rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("private:user")); + pArg[0].Name = rtl::OUString("Referer"); + pArg[0].Value <<= rtl::OUString("private:user"); - dispatchURL( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(OPEN_URL) ), rtl::OUString(), xFrame, aArgs ); + dispatchURL( rtl::OUString( OPEN_URL ), rtl::OUString(), xFrame, aArgs ); } else if( pButton == &maTemplateButton ) { @@ -924,10 +924,10 @@ IMPL_LINK( BackingWindow, ClickHdl, Button*, pButton ) Sequence< com::sun::star::beans::PropertyValue > aArgs(1); PropertyValue* pArg = aArgs.getArray(); - pArg[0].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Referer")); - pArg[0].Value <<= rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("private:user")); + pArg[0].Name = rtl::OUString("Referer"); + pArg[0].Value <<= rtl::OUString("private:user"); - dispatchURL( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(TEMPLATE_URL) ), rtl::OUString(), xFrame, aArgs ); + dispatchURL( rtl::OUString( TEMPLATE_URL ), rtl::OUString(), xFrame, aArgs ); } return 0; } @@ -1004,7 +1004,7 @@ void BackingWindow::dispatchURL( const rtl::OUString& i_rURL, aDispatchURL.Complete = i_rURL; Reference < com::sun::star::util::XURLTransformer > xURLTransformer( - comphelper::getProcessServiceFactory()->createInstance( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.util.URLTransformer")) ), + comphelper::getProcessServiceFactory()->createInstance( rtl::OUString("com.sun.star.util.URLTransformer") ), com::sun::star::uno::UNO_QUERY ); if ( xURLTransformer.is() ) { diff --git a/framework/source/services/dispatchhelper.cxx b/framework/source/services/dispatchhelper.cxx index 690d39c158c8..a64f8b8357c1 100644 --- a/framework/source/services/dispatchhelper.cxx +++ b/framework/source/services/dispatchhelper.cxx @@ -146,7 +146,7 @@ css::uno::Any SAL_CALL DispatchHelper::executeDispatch( css::uno::Sequence< css::beans::PropertyValue > aArguments( lArguments ); sal_Int32 nLength = lArguments.getLength(); aArguments.realloc( nLength + 1 ); - aArguments[ nLength ].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SynchronMode")); + aArguments[ nLength ].Name = ::rtl::OUString("SynchronMode"); aArguments[ nLength ].Value <<= (sal_Bool) sal_True; css::uno::Any aResult; diff --git a/framework/source/services/frame.cxx b/framework/source/services/frame.cxx index 87eabe25ab3e..d100e097ffec 100644 --- a/framework/source/services/frame.cxx +++ b/framework/source/services/frame.cxx @@ -530,7 +530,7 @@ void SAL_CALL Frame::initialize( const css::uno::Reference< css::awt::XWindow >& /* UNSAFE AREA --------------------------------------------------------------------------------------------- */ if (!xWindow.is()) throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Frame::initialize() called without a valid container window reference.")), + ::rtl::OUString("Frame::initialize() called without a valid container window reference."), static_cast< css::frame::XFrame* >(this)); /* SAFE AREA ----------------------------------------------------------------------------------------------- */ @@ -538,7 +538,7 @@ void SAL_CALL Frame::initialize( const css::uno::Reference< css::awt::XWindow >& if ( m_xContainerWindow.is() ) throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Frame::initialized() is called more then once, which isnt usefull nor allowed.")), + ::rtl::OUString("Frame::initialized() is called more then once, which isnt usefull nor allowed."), static_cast< css::frame::XFrame* >(this)); // Look for rejected calls first! diff --git a/framework/source/services/license.cxx b/framework/source/services/license.cxx index a8cbc53a082b..97e85190f30d 100644 --- a/framework/source/services/license.cxx +++ b/framework/source/services/license.cxx @@ -209,7 +209,7 @@ static sal_Bool _parseDateTime(const ::rtl::OUString& aString, DateTime& aDateTi sal_Int32 nDateLength = 10; sal_Int32 nTimeLength = 8; - ::rtl::OUString aUTCString(RTL_CONSTASCII_USTRINGPARAM("Z")); + ::rtl::OUString aUTCString("Z"); ::rtl::OUString aDateString = aDateTimeString.copy(0, nDateLength); ::rtl::OUString aTimeString = aDateTimeString.copy(nDateLength+1, nTimeLength); @@ -266,11 +266,11 @@ css::uno::Any SAL_CALL License::execute(const css::uno::Sequence< css::beans::Na aLangString = aLocale.Language; if ( !aLocale.Country.isEmpty() ) { - aLangString += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("-")); + aLangString += ::rtl::OUString("-"); aLangString += aLocale.Country; if ( !aLocale.Variant.isEmpty() ) { - aLangString += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("-")); + aLangString += ::rtl::OUString("-"); aLangString += aLocale.Variant; } } @@ -278,36 +278,36 @@ css::uno::Any SAL_CALL License::execute(const css::uno::Sequence< css::beans::Na ::rtl::OUString aLicensePath = aBaseInstallPath + ::rtl::OUString::createFromAscii(szLicensePath) + ::rtl::OUString::createFromAscii(szWNTLicenseName) - + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_")) + + ::rtl::OUString("_") + aLangString + ::rtl::OUString::createFromAscii(szWNTLicenseExt); #else ::rtl::OUString aLicensePath = aBaseInstallPath + ::rtl::OUString::createFromAscii(szLicensePath) + ::rtl::OUString::createFromAscii(szUNXLicenseName) - + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_")) + + ::rtl::OUString("_") + aLangString + ::rtl::OUString::createFromAscii(szUNXLicenseExt); #endif // check if we need to show the license at all // open org.openoffice.Setup/Office/ooLicenseAcceptDate ::rtl::OUString sConfigSrvc = SERVICENAME_CFGPROVIDER; - ::rtl::OUString sAccessSrvc(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationUpdateAccess")); + ::rtl::OUString sAccessSrvc("com.sun.star.configuration.ConfigurationUpdateAccess"); // get configuration provider Reference< XMultiServiceFactory > theConfigProvider = Reference< XMultiServiceFactory >( m_xFactory->createInstance(sConfigSrvc), UNO_QUERY_THROW); Sequence< Any > theArgs(1); NamedValue v; - v.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("NodePath")); - v.Value <<= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Setup/Office")); + v.Name = ::rtl::OUString("NodePath"); + v.Value <<= ::rtl::OUString("org.openoffice.Setup/Office"); theArgs[0] <<= v; Reference< XPropertySet > pset = Reference< XPropertySet >( theConfigProvider->createInstanceWithArguments(sAccessSrvc, theArgs), UNO_QUERY_THROW); // if we find a date there, compare it to baseinstall license date ::rtl::OUString aAcceptDate; - if (pset->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooLicenseAcceptDate"))) >>= aAcceptDate) + if (pset->getPropertyValue(::rtl::OUString("ooLicenseAcceptDate")) >>= aAcceptDate) { // get LicenseFileDate from base install ::rtl::OUString aLicenseURL = aLicensePath; @@ -341,7 +341,7 @@ css::uno::Any SAL_CALL License::execute(const css::uno::Sequence< css::beans::Na // write org.openoffice.Setup/ooLicenseAcceptDate aAcceptDate = _getCurrentDateString(); - pset->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooLicenseAcceptDate")), makeAny(aAcceptDate)); + pset->setPropertyValue(::rtl::OUString("ooLicenseAcceptDate"), makeAny(aAcceptDate)); Reference< XChangesBatch >(pset, UNO_QUERY_THROW)->commitChanges(); // enable quickstarter @@ -352,7 +352,7 @@ css::uno::Any SAL_CALL License::execute(const css::uno::Sequence< css::beans::Na aSeq[1] <<= bAutostart; Reference < XInitialization > xQuickstart( ::comphelper::getProcessServiceFactory()->createInstance( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.office.Quickstart"))),UNO_QUERY ); + ::rtl::OUString("com.sun.star.office.Quickstart")),UNO_QUERY ); if ( xQuickstart.is() ) xQuickstart->initialize( aSeq ); diff --git a/framework/source/services/modulemanager.cxx b/framework/source/services/modulemanager.cxx index e412d82d7167..ce2d959a2d25 100644 --- a/framework/source/services/modulemanager.cxx +++ b/framework/source/services/modulemanager.cxx @@ -117,7 +117,7 @@ ModuleManager::~ModuleManager() ) { throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Given module is not a frame nor a window, controller or model.")), + ::rtl::OUString("Given module is not a frame nor a window, controller or model."), static_cast< ::cppu::OWeakObject* >(this), 1); } @@ -147,7 +147,7 @@ ModuleManager::~ModuleManager() if (sModule.isEmpty()) throw css::frame::UnknownModuleException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Cant find suitable module for the given component.")), + ::rtl::OUString("Cant find suitable module for the given component."), static_cast< ::cppu::OWeakObject* >(this)); return sModule; @@ -164,7 +164,7 @@ void SAL_CALL ModuleManager::replaceByName(const ::rtl::OUString& sName , if (lProps.empty() ) { throw css::lang::IllegalArgumentException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("No properties given to replace part of module.")), + ::rtl::OUString("No properties given to replace part of module."), static_cast< css::container::XNameAccess* >(this), 2); } @@ -191,7 +191,7 @@ void SAL_CALL ModuleManager::replaceByName(const ::rtl::OUString& sName , if (!xModule.is()) { throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Was not able to get write access to the requested module entry inside configuration.")), + ::rtl::OUString("Was not able to get write access to the requested module entry inside configuration."), static_cast< css::container::XNameAccess* >(this)); } @@ -223,7 +223,7 @@ css::uno::Any SAL_CALL ModuleManager::getByName(const ::rtl::OUString& sName) if (!xModule.is()) { throw css::uno::RuntimeException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Was not able to get write access to the requested module entry inside configuration.")), + ::rtl::OUString("Was not able to get write access to the requested module entry inside configuration."), static_cast< css::container::XNameAccess* >(this)); } diff --git a/framework/source/services/sessionlistener.cxx b/framework/source/services/sessionlistener.cxx index 55bed9b4b9dc..1f52d37b9cb3 100644 --- a/framework/source/services/sessionlistener.cxx +++ b/framework/source/services/sessionlistener.cxx @@ -164,7 +164,7 @@ void SessionListener::StoreSession( sal_Bool bAsync ) css::uno::Reference< XDispatch > xDispatch(m_xSMGR->createInstance(SERVICENAME_AUTORECOVERY), UNO_QUERY_THROW); css::uno::Reference< XURLTransformer > xURLTransformer(m_xSMGR->createInstance(SERVICENAME_URLTRANSFORMER), UNO_QUERY_THROW); URL aURL; - aURL.Complete = OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.star.autorecovery:/doSessionSave")); + aURL.Complete = OUString("vnd.sun.star.autorecovery:/doSessionSave"); xURLTransformer->parseStrict(aURL); // in case of asynchronous call the notification will trigger saveDone() @@ -172,7 +172,7 @@ void SessionListener::StoreSession( sal_Bool bAsync ) xDispatch->addStatusListener(this, aURL); Sequence< PropertyValue > args(1); - args[0] = PropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("DispatchAsynchron")),-1,makeAny(bAsync),PropertyState_DIRECT_VALUE); + args[0] = PropertyValue(OUString("DispatchAsynchron"),-1,makeAny(bAsync),PropertyState_DIRECT_VALUE); xDispatch->dispatch(aURL, args); } catch (const com::sun::star::uno::Exception& e) { OString aMsg = OUStringToOString(e.Message, RTL_TEXTENCODING_UTF8); @@ -197,11 +197,11 @@ void SessionListener::QuitSessionQuietly() css::uno::Reference< XDispatch > xDispatch(m_xSMGR->createInstance(SERVICENAME_AUTORECOVERY), UNO_QUERY_THROW); css::uno::Reference< XURLTransformer > xURLTransformer(m_xSMGR->createInstance(SERVICENAME_URLTRANSFORMER), UNO_QUERY_THROW); URL aURL; - aURL.Complete = OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.star.autorecovery:/doSessionQuietQuit")); + aURL.Complete = OUString("vnd.sun.star.autorecovery:/doSessionQuietQuit"); xURLTransformer->parseStrict(aURL); Sequence< PropertyValue > args(1); - args[0] = PropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("DispatchAsynchron")),-1,makeAny(sal_False),PropertyState_DIRECT_VALUE); + args[0] = PropertyValue(OUString("DispatchAsynchron"),-1,makeAny(sal_False),PropertyState_DIRECT_VALUE); xDispatch->dispatch(aURL, args); } catch (const com::sun::star::uno::Exception& e) { OString aMsg = OUStringToOString(e.Message, RTL_TEXTENCODING_UTF8); @@ -219,7 +219,7 @@ void SAL_CALL SessionListener::initialize(const Sequence< Any >& args) { SAL_INFO("fwk.session", "SessionListener::initialize"); - OUString aSMgr(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.SessionManagerClient")); + OUString aSMgr("com.sun.star.frame.SessionManagerClient"); if (args.getLength() > 0) { NamedValue v; @@ -277,7 +277,7 @@ sal_Bool SAL_CALL SessionListener::doRestore() css::uno::Reference< XDispatch > xDispatch(m_xSMGR->createInstance(SERVICENAME_AUTORECOVERY), UNO_QUERY_THROW); URL aURL; - aURL.Complete = OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.star.autorecovery:/doSessionRestore")); + aURL.Complete = OUString("vnd.sun.star.autorecovery:/doSessionRestore"); css::uno::Reference< XURLTransformer > xURLTransformer(m_xSMGR->createInstance(SERVICENAME_URLTRANSFORMER), UNO_QUERY_THROW); xURLTransformer->parseStrict(aURL); Sequence< PropertyValue > args; diff --git a/framework/source/services/tabwindowservice.cxx b/framework/source/services/tabwindowservice.cxx index 8b021cd15325..94a79fc7372b 100644 --- a/framework/source/services/tabwindowservice.cxx +++ b/framework/source/services/tabwindowservice.cxx @@ -320,7 +320,7 @@ void TabWindowService::impl_initializePropInfo() impl_addPropertyInfo( css::beans::Property( - rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Window")), + rtl::OUString("Window"), TABWINDOWSERVICE_PROPHANDLE_WINDOW, ::getCppuType((const css::uno::Reference< css::awt::XWindow >*)NULL), css::beans::PropertyAttribute::TRANSIENT)); @@ -438,7 +438,7 @@ void TabWindowService::impl_checkTabIndex (::sal_Int32 nID) ) { throw css::lang::IndexOutOfBoundsException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Tab index out of bounds.")), + ::rtl::OUString("Tab index out of bounds."), css::uno::Reference< css::uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this), css::uno::UNO_QUERY )); } } @@ -452,7 +452,7 @@ TTabPageInfoHash::iterator TabWindowService::impl_getTabPageInfo(::sal_Int32 nID TTabPageInfoHash::iterator pIt = m_lTabPageInfos.find(nID); if (pIt == m_lTabPageInfos.end ()) throw css::lang::IndexOutOfBoundsException( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Tab index out of bounds.")), + ::rtl::OUString("Tab index out of bounds."), css::uno::Reference< css::uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this), css::uno::UNO_QUERY )); return pIt; } diff --git a/framework/source/services/urltransformer.cxx b/framework/source/services/urltransformer.cxx index 4e782139bc38..132143e58c43 100644 --- a/framework/source/services/urltransformer.cxx +++ b/framework/source/services/urltransformer.cxx @@ -348,7 +348,7 @@ sal_Bool SAL_CALL URLTransformer::assemble( URL& aURL ) throw( RuntimeException if ( !bWithPassword && !aTestURL.Password.isEmpty() ) { // Exchange password text with other placeholder string - aTestURL.Password = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("<******>")); + aTestURL.Password = ::rtl::OUString("<******>"); assemble( aTestURL ); } diff --git a/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx b/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx index 8e4aec67c385..f6b3eab3f008 100644 --- a/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx +++ b/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx @@ -128,7 +128,7 @@ static const char RESOURCEURL_CUSTOM_ELEMENT[] = "custom_"; static sal_Int16 RetrieveTypeFromResourceURL( const rtl::OUString& aResourceURL ) { - if (( aResourceURL.indexOf( OUString( RTL_CONSTASCII_USTRINGPARAM( RESOURCEURL_PREFIX ))) == 0 ) && + if (( aResourceURL.indexOf( OUString( RESOURCEURL_PREFIX )) == 0 ) && ( aResourceURL.getLength() > RESOURCEURL_PREFIX_SIZE )) { OUString aTmpStr = aResourceURL.copy( RESOURCEURL_PREFIX_SIZE ); @@ -149,7 +149,7 @@ static sal_Int16 RetrieveTypeFromResourceURL( const rtl::OUString& aResourceURL static OUString RetrieveNameFromResourceURL( const rtl::OUString& aResourceURL ) { - if (( aResourceURL.indexOf( OUString( RTL_CONSTASCII_USTRINGPARAM( RESOURCEURL_PREFIX ))) == 0 ) && + if (( aResourceURL.indexOf( OUString( RESOURCEURL_PREFIX )) == 0 ) && ( aResourceURL.getLength() > RESOURCEURL_PREFIX_SIZE )) { sal_Int32 nIndex = aResourceURL.lastIndexOf( '/' ); @@ -169,7 +169,7 @@ void ModuleUIConfigurationManager::impl_fillSequenceWithElementTypeInfo( UIEleme UIElementDataHashMap& rUserElements = m_aUIElements[LAYER_USERDEFINED][nElementType].aElementsHashMap; UIElementDataHashMap::const_iterator pUserIter = rUserElements.begin(); - OUString aCustomUrlPrefix( RTL_CONSTASCII_USTRINGPARAM( RESOURCEURL_CUSTOM_ELEMENT )); + OUString aCustomUrlPrefix( RESOURCEURL_CUSTOM_ELEMENT ); while ( pUserIter != rUserElements.end() ) { sal_Int32 nIndex = pUserIter->second.aResourceURL.indexOf( aCustomUrlPrefix, RESOURCEURL_PREFIX_SIZE ); @@ -744,9 +744,9 @@ ModuleUIConfigurationManager::ModuleUIConfigurationManager( com::sun::star::uno: , m_bModified( false ) , m_bConfigRead( false ) , m_bDisposed( false ) - , m_aXMLPostfix( RTL_CONSTASCII_USTRINGPARAM( ".xml" )) - , m_aPropUIName( RTL_CONSTASCII_USTRINGPARAM( "UIName" )) - , m_aPropResourceURL( RTL_CONSTASCII_USTRINGPARAM( "ResourceURL" )) + , m_aXMLPostfix( ".xml" ) + , m_aPropUIName( "UIName" ) + , m_aPropResourceURL( "ResourceURL" ) , m_xServiceManager( xServiceManager ) , m_aListenerContainer( m_aLock.getShareableOslMutex() ) { @@ -826,8 +826,8 @@ void SAL_CALL ModuleUIConfigurationManager::initialize( const Sequence< Any >& a if ( !m_bInitialized ) { ::comphelper::SequenceAsHashMap lArgs(aArguments); - m_aModuleIdentifier = lArgs.getUnpackedValueOrDefault(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ModuleIdentifier")), ::rtl::OUString()); - m_aModuleShortName = lArgs.getUnpackedValueOrDefault(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ModuleShortName")), ::rtl::OUString()); + m_aModuleIdentifier = lArgs.getUnpackedValueOrDefault(::rtl::OUString("ModuleIdentifier"), ::rtl::OUString()); + m_aModuleShortName = lArgs.getUnpackedValueOrDefault(::rtl::OUString("ModuleShortName"), ::rtl::OUString()); for ( int i = 1; i < ::com::sun::star::ui::UIElementType::COUNT; i++ ) { @@ -863,7 +863,7 @@ void SAL_CALL ModuleUIConfigurationManager::initialize( const Sequence< Any >& a if ( xPropSet.is() ) { long nOpenMode = 0; - Any a = xPropSet->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "OpenMode" ))); + Any a = xPropSet->getPropertyValue( rtl::OUString( "OpenMode" )); if ( a >>= nOpenMode ) m_bReadOnly = !( nOpenMode & ElementModes::WRITE ); } @@ -1352,13 +1352,13 @@ Reference< XInterface > SAL_CALL ModuleUIConfigurationManager::getImageManager() Sequence< Any > aPropSeq( 3 ); PropertyValue aPropValue; - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "UserConfigStorage" )); + aPropValue.Name = rtl::OUString( "UserConfigStorage" ); aPropValue.Value = makeAny( m_xUserConfigStorage ); aPropSeq[0] = makeAny( aPropValue ); - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ModuleIdentifier" )); + aPropValue.Name = rtl::OUString( "ModuleIdentifier" ); aPropValue.Value = makeAny( m_aModuleIdentifier ); aPropSeq[1] = makeAny( aPropValue ); - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "UserRootCommit" )); + aPropValue.Name = rtl::OUString( "UserRootCommit" ); aPropValue.Value = makeAny( m_xUserRootCommit ); aPropSeq[2] = makeAny( aPropValue ); @@ -1384,7 +1384,7 @@ Reference< XInterface > SAL_CALL ModuleUIConfigurationManager::getShortCutManage Reference< XInitialization > xInit (xManager, UNO_QUERY_THROW); PropertyValue aProp; - aProp.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ModuleIdentifier")); + aProp.Name = ::rtl::OUString("ModuleIdentifier"); aProp.Value <<= aModule; Sequence< Any > lArgs(1); diff --git a/framework/source/uiconfiguration/uiconfigurationmanager.cxx b/framework/source/uiconfiguration/uiconfigurationmanager.cxx index f0caf7f0daad..34eb8a93311b 100644 --- a/framework/source/uiconfiguration/uiconfigurationmanager.cxx +++ b/framework/source/uiconfiguration/uiconfigurationmanager.cxx @@ -125,7 +125,7 @@ static const sal_Int32 RESOURCEURL_PREFIX_SIZE = 17; static sal_Int16 RetrieveTypeFromResourceURL( const rtl::OUString& aResourceURL ) { - if (( aResourceURL.indexOf( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( RESOURCEURL_PREFIX ))) == 0 ) && + if (( aResourceURL.indexOf( rtl::OUString( RESOURCEURL_PREFIX )) == 0 ) && ( aResourceURL.getLength() > RESOURCEURL_PREFIX_SIZE )) { rtl::OUString aTmpStr = aResourceURL.copy( RESOURCEURL_PREFIX_SIZE ); @@ -146,7 +146,7 @@ static sal_Int16 RetrieveTypeFromResourceURL( const rtl::OUString& aResourceURL static rtl::OUString RetrieveNameFromResourceURL( const rtl::OUString& aResourceURL ) { - if (( aResourceURL.indexOf( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( RESOURCEURL_PREFIX ))) == 0 ) && + if (( aResourceURL.indexOf( rtl::OUString( RESOURCEURL_PREFIX )) == 0 ) && ( aResourceURL.getLength() > RESOURCEURL_PREFIX_SIZE )) { sal_Int32 nIndex = aResourceURL.lastIndexOf( '/' ); @@ -601,9 +601,9 @@ UIConfigurationManager::UIConfigurationManager( com::sun::star::uno::Reference< , m_bModified( false ) , m_bConfigRead( false ) , m_bDisposed( false ) - , m_aXMLPostfix( RTL_CONSTASCII_USTRINGPARAM( ".xml" )) - , m_aPropUIName( RTL_CONSTASCII_USTRINGPARAM( "UIName" )) - , m_aPropResourceURL( RTL_CONSTASCII_USTRINGPARAM( "ResourceURL" )) + , m_aXMLPostfix( ".xml" ) + , m_aPropUIName( "UIName" ) + , m_aPropResourceURL( "ResourceURL" ) , m_xServiceManager( xServiceManager ) , m_aListenerContainer( m_aLock.getShareableOslMutex() ) { @@ -1072,10 +1072,10 @@ Reference< XInterface > SAL_CALL UIConfigurationManager::getImageManager() throw Sequence< Any > aPropSeq( 2 ); PropertyValue aPropValue; - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "UserConfigStorage" )); + aPropValue.Name = rtl::OUString( "UserConfigStorage" ); aPropValue.Value = makeAny( m_xDocConfigStorage ); aPropSeq[0] = makeAny( aPropValue ); - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ModuleIdentifier" )); + aPropValue.Name = rtl::OUString( "ModuleIdentifier" ); aPropValue.Value = makeAny( m_aModuleIdentifier ); aPropSeq[1] = makeAny( aPropValue ); @@ -1103,7 +1103,7 @@ Reference< XInterface > SAL_CALL UIConfigurationManager::getShortCutManager() th Reference< XInitialization > xInit (xAccConfig, UNO_QUERY_THROW); PropertyValue aProp; - aProp.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DocumentRoot")); + aProp.Name = ::rtl::OUString("DocumentRoot"); aProp.Value <<= xDocumentRoot; Sequence< Any > lArgs(1); @@ -1170,7 +1170,7 @@ void SAL_CALL UIConfigurationManager::setStorage( const Reference< XStorage >& S try { long nOpenMode = 0; - Any a = xPropSet->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "OpenMode" ))); + Any a = xPropSet->getPropertyValue( rtl::OUString( "OpenMode" )); if ( a >>= nOpenMode ) m_bReadOnly = !( nOpenMode & ElementModes::WRITE ); } diff --git a/framework/source/uiconfiguration/windowstateconfiguration.cxx b/framework/source/uiconfiguration/windowstateconfiguration.cxx index bc68f637add3..f9d635d23089 100644 --- a/framework/source/uiconfiguration/windowstateconfiguration.cxx +++ b/framework/source/uiconfiguration/windowstateconfiguration.cxx @@ -295,14 +295,14 @@ DEFINE_XTYPEPROVIDER_7 ( ConfigurationAccess_WindowState , ConfigurationAccess_WindowState::ConfigurationAccess_WindowState( const rtl::OUString& aModuleName, const Reference< XMultiServiceFactory >& rServiceManager ) : ThreadHelpBase(), - m_aConfigWindowAccess( RTL_CONSTASCII_USTRINGPARAM( CONFIGURATION_ROOT_ACCESS )), + m_aConfigWindowAccess( CONFIGURATION_ROOT_ACCESS ), m_xServiceManager( rServiceManager ), m_bConfigAccessInitialized( sal_False ), m_bModified( sal_False ) { // Create configuration hierachical access name m_aConfigWindowAccess += aModuleName; - m_aConfigWindowAccess += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CONFIGURATION_WINDOWSTATE_ACCESS )); + m_aConfigWindowAccess += rtl::OUString( CONFIGURATION_WINDOWSTATE_ACCESS ); m_xConfigProvider = Reference< XMultiServiceFactory >( rServiceManager->createInstance( SERVICENAME_CFGPROVIDER ), UNO_QUERY ); // Initialize access array with property names. @@ -1224,7 +1224,7 @@ void ConfigurationAccess_WindowState::impl_putPropertiesFromStruct( const Window sal_Int32 i( 0 ); sal_Int32 nCount( m_aPropArray.size() ); Sequence< PropertyValue > aPropSeq; - ::rtl::OUString aDelim( RTL_CONSTASCII_USTRINGPARAM(",") ); + ::rtl::OUString aDelim( "," ); for ( i = 0; i < nCount; i++ ) { @@ -1309,10 +1309,10 @@ sal_Bool ConfigurationAccess_WindowState::impl_initializeConfigAccess() try { - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "nodepath" )); + aPropValue.Name = rtl::OUString( "nodepath" ); aPropValue.Value <<= m_aConfigWindowAccess; aArgs[0] <<= aPropValue; - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "lazywrite" )); + aPropValue.Name = rtl::OUString( "lazywrite" ); aPropValue.Value <<= sal_True; aArgs[1] <<= aPropValue; diff --git a/framework/source/uielement/buttontoolbarcontroller.cxx b/framework/source/uielement/buttontoolbarcontroller.cxx index 5840780258bb..7061386a398b 100644 --- a/framework/source/uielement/buttontoolbarcontroller.cxx +++ b/framework/source/uielement/buttontoolbarcontroller.cxx @@ -245,7 +245,7 @@ throw (::com::sun::star::uno::RuntimeException) if ( !m_xURLTransformer.is() ) { m_xURLTransformer = uno::Reference< util::XURLTransformer >( - m_xServiceManager->createInstance( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.util.URLTransformer" ))), + m_xServiceManager->createInstance( rtl::OUString( "com.sun.star.util.URLTransformer" )), uno::UNO_QUERY_THROW ); } @@ -270,7 +270,7 @@ throw (::com::sun::star::uno::RuntimeException) Sequence<PropertyValue> aArgs( 1 ); // Provide key modifier information to dispatch function - aArgs[0].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "KeyModifier" )); + aArgs[0].Name = rtl::OUString( "KeyModifier" ); aArgs[0].Value <<= KeyModifier; xDispatch->dispatch( aTargetURL, aArgs ); diff --git a/framework/source/uielement/complextoolbarcontroller.cxx b/framework/source/uielement/complextoolbarcontroller.cxx index a9ba6c5b4f56..c7badf678f91 100644 --- a/framework/source/uielement/complextoolbarcontroller.cxx +++ b/framework/source/uielement/complextoolbarcontroller.cxx @@ -81,7 +81,7 @@ ComplexToolbarController::ComplexToolbarController( , m_bMadeInvisible( sal_False ) { m_xURLTransformer.set( m_xServiceManager->createInstance( - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.util.URLTransformer" ))), + rtl::OUString( "com.sun.star.util.URLTransformer" )), UNO_QUERY_THROW ); } @@ -112,7 +112,7 @@ Sequence<PropertyValue> ComplexToolbarController::getExecuteArgs(sal_Int16 KeyMo Sequence<PropertyValue> aArgs( 1 ); // Add key modifier to argument list - aArgs[0].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "KeyModifier" )); + aArgs[0].Name = rtl::OUString( "KeyModifier" ); aArgs[0].Value <<= KeyModifier; return aArgs; } @@ -294,7 +294,7 @@ void ComplexToolbarController::addNotifyInfo( sal_Int32 nCount = rInfo.getLength(); uno::Sequence< beans::NamedValue > aInfoSeq( rInfo ); aInfoSeq.realloc( nCount+1 ); - aInfoSeq[nCount].Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Source" )); + aInfoSeq[nCount].Name = ::rtl::OUString( "Source" ); aInfoSeq[nCount].Value = uno::makeAny( getFrameInterface() ); pNotifyInfo->aInfoSeq = aInfoSeq; @@ -346,7 +346,7 @@ void ComplexToolbarController::notifyFocusGet() { // send focus get notification uno::Sequence< beans::NamedValue > aInfo; - addNotifyInfo( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FocusSet" )), + addNotifyInfo( rtl::OUString( "FocusSet" ), getDispatchFromCommand( m_aCommandURL ), aInfo ); } @@ -355,7 +355,7 @@ void ComplexToolbarController::notifyFocusLost() { // send focus lost notification uno::Sequence< beans::NamedValue > aInfo; - addNotifyInfo( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FocusLost" )), + addNotifyInfo( rtl::OUString( "FocusLost" ), getDispatchFromCommand( m_aCommandURL ), aInfo ); } @@ -364,9 +364,9 @@ void ComplexToolbarController::notifyTextChanged( const ::rtl::OUString& aText ) { // send text changed notification uno::Sequence< beans::NamedValue > aInfo( 1 ); - aInfo[0].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Text" )); + aInfo[0].Name = rtl::OUString( "Text" ); aInfo[0].Value <<= aText; - addNotifyInfo( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "TextChanged" )), + addNotifyInfo( rtl::OUString( "TextChanged" ), getDispatchFromCommand( m_aCommandURL ), aInfo ); } diff --git a/framework/source/uielement/fontmenucontroller.cxx b/framework/source/uielement/fontmenucontroller.cxx index 1c437f8ea75d..2c2177bf4a00 100644 --- a/framework/source/uielement/fontmenucontroller.cxx +++ b/framework/source/uielement/fontmenucontroller.cxx @@ -116,7 +116,7 @@ void FontMenuController::fillPopupMenu( const Sequence< ::rtl::OUString >& rFont } sort(aVector.begin(), aVector.end(), lcl_I18nCompareString ); - const rtl::OUString aFontNameCommandPrefix( RTL_CONSTASCII_USTRINGPARAM( ".uno:CharFontName?CharFontName.FamilyName:string=" )); + const rtl::OUString aFontNameCommandPrefix( ".uno:CharFontName?CharFontName.FamilyName:string=" ); const sal_Int16 nCount = (sal_Int16)aVector.size(); for ( sal_Int16 i = 0; i < nCount; i++ ) { @@ -222,7 +222,7 @@ void FontMenuController::impl_setPopupMenu() com::sun::star::util::URL aTargetURL; // Register for font list updates to get the current font list from the controller - aTargetURL.Complete = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:FontNameList" )); + aTargetURL.Complete = rtl::OUString( ".uno:FontNameList" ); m_xURLTransformer->parseStrict( aTargetURL ); m_xFontListDispatch = xDispatchProvider->queryDispatch( aTargetURL, ::rtl::OUString(), 0 ); } @@ -234,7 +234,7 @@ void SAL_CALL FontMenuController::updatePopupMenu() throw ( ::com::sun::star::un osl::ClearableMutexGuard aLock( m_aMutex ); Reference< XDispatch > xDispatch( m_xFontListDispatch ); com::sun::star::util::URL aTargetURL; - aTargetURL.Complete = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:FontNameList" )); + aTargetURL.Complete = rtl::OUString( ".uno:FontNameList" ); m_xURLTransformer->parseStrict( aTargetURL ); aLock.clear(); diff --git a/framework/source/uielement/fontsizemenucontroller.cxx b/framework/source/uielement/fontsizemenucontroller.cxx index f9bbc8500dc7..eaa44efa067f 100644 --- a/framework/source/uielement/fontsizemenucontroller.cxx +++ b/framework/source/uielement/fontsizemenucontroller.cxx @@ -188,7 +188,7 @@ void FontSizeMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu >& r nSizeCount++; sal_uInt16 nPos = 0; - const rtl::OUString aFontHeightCommand( RTL_CONSTASCII_USTRINGPARAM( ".uno:FontHeight?FontHeight.Height:float=" )); + const rtl::OUString aFontHeightCommand( ".uno:FontHeight?FontHeight.Height:float=" ); // first insert font size names (for simplified/traditional chinese) float fPoint; @@ -320,7 +320,7 @@ void FontSizeMenuController::impl_setPopupMenu() Reference< XDispatchProvider > xDispatchProvider( m_xFrame, UNO_QUERY ); com::sun::star::util::URL aTargetURL; // Register for font name updates which gives us info about the current font! - aTargetURL.Complete = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:CharFontName" )); + aTargetURL.Complete = rtl::OUString( ".uno:CharFontName" ); m_xURLTransformer->parseStrict( aTargetURL ); m_xCurrentFontDispatch = xDispatchProvider->queryDispatch( aTargetURL, ::rtl::OUString(), 0 ); } @@ -333,7 +333,7 @@ void SAL_CALL FontSizeMenuController::updatePopupMenu() throw ( ::com::sun::star Reference< XDispatch > xDispatch( m_xCurrentFontDispatch ); com::sun::star::util::URL aTargetURL; - aTargetURL.Complete = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:CharFontName" )); + aTargetURL.Complete = rtl::OUString( ".uno:CharFontName" ); m_xURLTransformer->parseStrict( aTargetURL ); aLock.clear(); diff --git a/framework/source/uielement/generictoolbarcontroller.cxx b/framework/source/uielement/generictoolbarcontroller.cxx index defc407db11e..58f05bbe083a 100644 --- a/framework/source/uielement/generictoolbarcontroller.cxx +++ b/framework/source/uielement/generictoolbarcontroller.cxx @@ -168,7 +168,7 @@ throw ( RuntimeException ) !m_aCommandURL.isEmpty() ) { xURLTransformer = Reference< XURLTransformer >( m_xServiceManager->createInstance( - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.util.URLTransformer" ))), + rtl::OUString( "com.sun.star.util.URLTransformer" )), UNO_QUERY ); aCommandURL = m_aCommandURL; @@ -184,7 +184,7 @@ throw ( RuntimeException ) Sequence<PropertyValue> aArgs( 1 ); // Add key modifier to argument list - aArgs[0].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "KeyModifier" )); + aArgs[0].Name = rtl::OUString( "KeyModifier" ); aArgs[0].Value <<= KeyModifier; aTargetURL.Complete = aCommandURL; @@ -251,7 +251,7 @@ throw ( RuntimeException ) { String aResStr = String( FwkResId( STR_UPDATEDOC )); rtl::OUString aTmp( aResStr ); - aTmp += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( " " )); + aTmp += rtl::OUString( " " ); aTmp += aStrValue.copy( 4 ); aStrValue = aTmp; } @@ -364,7 +364,7 @@ MenuToolbarController::createPopupWindow() throw (::com::sun::star::uno::Runtime if ( !pMenu ) { Reference< XDispatchProvider > xDispatch; - Reference< XURLTransformer > xURLTransformer( m_xServiceManager->createInstance( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.util.URLTransformer" ))), UNO_QUERY ); + Reference< XURLTransformer > xURLTransformer( m_xServiceManager->createInstance( rtl::OUString( "com.sun.star.util.URLTransformer" )), UNO_QUERY ); pMenu = new Toolbarmenu(); m_xMenuManager.set( new MenuBarManager( m_xServiceManager, m_xFrame, xURLTransformer, xDispatch, m_aModuleIdentifier, pMenu, sal_True, sal_True ) ); if ( m_xMenuManager.is() ) diff --git a/framework/source/uielement/langselectionmenucontroller.cxx b/framework/source/uielement/langselectionmenucontroller.cxx index 9d1cd2ac76d7..5bac99419694 100644 --- a/framework/source/uielement/langselectionmenucontroller.cxx +++ b/framework/source/uielement/langselectionmenucontroller.cxx @@ -259,7 +259,7 @@ void LanguageSelectionMenuController::fillPopupMenu( Reference< css::awt::XPopup // for aCmd_Dialog and aCmd_Language sal_Int16 nItemId = 1; // in this control the item id is not important for executing the command - const OUString sAsterix(RTL_CONSTASCII_USTRINGPARAM("*")); // multiple languages in current selection + const OUString sAsterix("*"); // multiple languages in current selection const OUString sEmpty; // 'no language found' from language guessing std::map< sal_Int16, OUString > aLangMap; std::set< OUString >::const_iterator it; @@ -351,10 +351,10 @@ void SAL_CALL LanguageSelectionMenuController::initialize( const Sequence< Any > if ( m_bInitialized ) { - m_aLangStatusCommandURL = OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:LanguageStatus" )); + m_aLangStatusCommandURL = OUString( ".uno:LanguageStatus" ); m_aMenuCommandURL_Lang = m_aLangStatusCommandURL; - m_aMenuCommandURL_Font = OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:FontDialog" )); - m_aMenuCommandURL_CharDlgForParagraph = OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:FontDialogForParagraph" )); + m_aMenuCommandURL_Font = OUString( ".uno:FontDialog" ); + m_aMenuCommandURL_CharDlgForParagraph = OUString( ".uno:FontDialogForParagraph" ); } } } diff --git a/framework/source/uielement/macrosmenucontroller.cxx b/framework/source/uielement/macrosmenucontroller.cxx index b954bce5e1bc..19676d3a2ca6 100644 --- a/framework/source/uielement/macrosmenucontroller.cxx +++ b/framework/source/uielement/macrosmenucontroller.cxx @@ -176,8 +176,8 @@ void MacrosMenuController::addScriptItems( PopupMenu* pPopupMenu, sal_uInt16 sta { const String aCmdBase = String::CreateFromAscii( ".uno:ScriptOrganizer?ScriptOrganizer.Language:string=" ); const String ellipsis = String::CreateFromAscii( "..." ); - const ::rtl::OUString providerKey(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.script.provider.ScriptProviderFor")); - const ::rtl::OUString languageProviderName(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.script.provider.LanguageScriptProvider")); + const ::rtl::OUString providerKey("com.sun.star.script.provider.ScriptProviderFor"); + const ::rtl::OUString languageProviderName("com.sun.star.script.provider.LanguageScriptProvider"); sal_uInt16 itemId = startItemId; Reference< XContentEnumerationAccess > xEnumAccess = Reference< XContentEnumerationAccess >( m_xServiceManager, UNO_QUERY_THROW ); Reference< XEnumeration > xEnum = xEnumAccess->createContentEnumeration ( languageProviderName ); diff --git a/framework/source/uielement/menubarmanager.cxx b/framework/source/uielement/menubarmanager.cxx index 0a3922d44d5d..d24da8c2b673 100644 --- a/framework/source/uielement/menubarmanager.cxx +++ b/framework/source/uielement/menubarmanager.cxx @@ -209,7 +209,7 @@ MenuBarManager::MenuBarManager( { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "framework", "Ocke.Janssen@sun.com", "MenuBarManager::MenuBarManager" ); m_xPopupMenuControllerRegistration = Reference< ::com::sun::star::frame::XUIControllerRegistration >( - getServiceFactory()->createInstance( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.frame.PopupMenuControllerFactory" ))), + getServiceFactory()->createInstance( rtl::OUString( "com.sun.star.frame.PopupMenuControllerFactory" )), UNO_QUERY ); FillMenuManager( pMenu, rFrame, rDispatchProvider, rModuleIdentifier, bDelete, bDeleteChildren ); } @@ -545,7 +545,7 @@ throw ( RuntimeException ) { String aResStr = String( FwkResId( STR_UPDATEDOC )); rtl::OUString aTmp( aResStr ); - aTmp += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( " " )); + aTmp += rtl::OUString( " " ); aTmp += aItemText.copy( 4 ); aItemText = aTmp; } @@ -921,7 +921,7 @@ IMPL_LINK( MenuBarManager, Activate, Menu *, pMenu ) ::rtl::OUString aItemCommand = pMenu->GetItemCommand( pMenuItemHandler->nItemId ); if ( aItemCommand.isEmpty() ) { - aItemCommand = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "slot:" )); + aItemCommand = ::rtl::OUString( "slot:" ); aItemCommand += ::rtl::OUString::valueOf( (sal_Int32)pMenuItemHandler->nItemId ); pMenu->SetItemCommand( pMenuItemHandler->nItemId, aItemCommand ); } @@ -1099,8 +1099,8 @@ IMPL_LINK( MenuBarManager, Select, Menu *, pMenu ) { // bookmark menu item selected aArgs.realloc( 1 ); - aArgs[0].Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Referer" )); - aArgs[0].Value <<= ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( SFX_REFERER_USER )); + aArgs[0].Name = ::rtl::OUString( "Referer" ); + aArgs[0].Value <<= ::rtl::OUString( SFX_REFERER_USER ); } xDispatch = pMenuItemHandler->xMenuItemDispatch; @@ -1187,17 +1187,17 @@ sal_Bool MenuBarManager::CreatePopupMenuController( MenuItemHandler* pMenuItemHa Sequence< Any > aSeq( 2 ); PropertyValue aPropValue; - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ModuleName" )); + aPropValue.Name = rtl::OUString( "ModuleName" ); aPropValue.Value <<= m_aModuleIdentifier; aSeq[0] <<= aPropValue; - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Frame" )); + aPropValue.Name = rtl::OUString( "Frame" ); aPropValue.Value <<= m_xFrame; aSeq[1] <<= aPropValue; Reference< XComponentContext > xComponentContext; Reference< XPropertySet > xProps( getServiceFactory(), UNO_QUERY ); - xProps->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "DefaultContext" ))) >>= + xProps->getPropertyValue( rtl::OUString( "DefaultContext" )) >>= xComponentContext; Reference< XPopupMenuController > xPopupMenuController( @@ -1370,7 +1370,7 @@ void MenuBarManager::FillMenuManager( Menu* pMenu, const Reference< XFrame >& rF pPopup->SetPopupMenu( ITEMID_ADDONLIST, pSubMenu ); // Set item command for popup menu to enable it for GetImageFromURL - const ::rtl::OUString aSlotString( RTL_CONSTASCII_USTRINGPARAM( "slot:" )); + const ::rtl::OUString aSlotString( "slot:" ); ::rtl::OUString aNewItemCommand( aSlotString ); aNewItemCommand += ::rtl::OUString::valueOf( (sal_Int32)ITEMID_ADDONLIST ); pPopup->SetItemCommand( ITEMID_ADDONLIST, aNewItemCommand ); @@ -1948,7 +1948,7 @@ void MenuBarManager::GetPopupController( PopupControllerCache& rPopupController // Just use the main part of the URL for popup menu controllers sal_Int32 nQueryPart( 0 ); sal_Int32 nSchemePart( 0 ); - rtl::OUString aMainURL( RTL_CONSTASCII_USTRINGPARAM( "vnd.sun.star.popup:" )); + rtl::OUString aMainURL( "vnd.sun.star.popup:" ); rtl::OUString aMenuURL( pItemHandler->aMenuItemURL ); nSchemePart = aMenuURL.indexOf( ':' ); @@ -2004,7 +2004,7 @@ sal_uInt16 MenuBarManager::FillItemCommand(::rtl::OUString& _rItemCommand,Menu* _rItemCommand = _pMenu->GetItemCommand( nItemId ); if ( _rItemCommand.isEmpty() ) { - const static ::rtl::OUString aSlotString( RTL_CONSTASCII_USTRINGPARAM( "slot:" )); + const static ::rtl::OUString aSlotString( "slot:" ); _rItemCommand = aSlotString; _rItemCommand += ::rtl::OUString::valueOf( (sal_Int32)nItemId ); _pMenu->SetItemCommand( nItemId, _rItemCommand ); @@ -2024,7 +2024,7 @@ void MenuBarManager::Init(const Reference< XFrame >& rFrame,AddonMenu* pAddonMen rtl::OUString aModuleIdentifier; m_xPopupMenuControllerRegistration = Reference< ::com::sun::star::frame::XUIControllerRegistration >( - getServiceFactory()->createInstance( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.frame.PopupMenuControllerFactory" ))), + getServiceFactory()->createInstance( rtl::OUString( "com.sun.star.frame.PopupMenuControllerFactory" )), UNO_QUERY ); Reference< XStatusListener > xStatusListener; diff --git a/framework/source/uielement/newmenucontroller.cxx b/framework/source/uielement/newmenucontroller.cxx index d82be5a8629a..8918b1f34f2f 100644 --- a/framework/source/uielement/newmenucontroller.cxx +++ b/framework/source/uielement/newmenucontroller.cxx @@ -326,7 +326,7 @@ NewMenuController::NewMenuController( const ::com::sun::star::uno::Reference< :: m_bNewMenu( sal_False ), m_bModuleIdentified( sal_False ), m_bAcceleratorCfg( sal_False ), - m_aTargetFrame( RTL_CONSTASCII_USTRINGPARAM( "_default" )) + m_aTargetFrame( "_default" ) { } @@ -440,8 +440,8 @@ void SAL_CALL NewMenuController::select( const css::awt::MenuEvent& rEvent ) thr xURLTransformer->parseStrict( aTargetURL ); - aArgsList[0].Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Referer" )); - aArgsList[0].Value = makeAny( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( SFX_REFERER_USER ))); + aArgsList[0].Name = ::rtl::OUString( "Referer" ); + aArgsList[0].Value = makeAny( ::rtl::OUString(SFX_REFERER_USER )); rtl::OUString aTargetFrame( m_aTargetFrame ); AddInfoForId::const_iterator pItem = m_aAddInfoForItem.find( rEvent.MenuId ); diff --git a/framework/source/uielement/objectmenucontroller.cxx b/framework/source/uielement/objectmenucontroller.cxx index ad69cb5f8671..668840b783ca 100644 --- a/framework/source/uielement/objectmenucontroller.cxx +++ b/framework/source/uielement/objectmenucontroller.cxx @@ -99,7 +99,7 @@ void ObjectMenuController::fillPopupMenu( const Sequence< com::sun::star::embed: if ( pVCLPopupMenu ) { - const rtl::OUString aVerbCommand( RTL_CONSTASCII_USTRINGPARAM( ".uno:ObjectMenue?VerbID:short=" )); + const rtl::OUString aVerbCommand( ".uno:ObjectMenue?VerbID:short=" ); for ( sal_uInt16 i = 0; i < rVerbCommandSeq.getLength(); i++ ) { const com::sun::star::embed::VerbDescriptor& rVerb = pVerbCommandArray[i]; diff --git a/framework/source/uielement/recentfilesmenucontroller.cxx b/framework/source/uielement/recentfilesmenucontroller.cxx index bbd00ab754af..b7496fe13603 100644 --- a/framework/source/uielement/recentfilesmenucontroller.cxx +++ b/framework/source/uielement/recentfilesmenucontroller.cxx @@ -132,7 +132,7 @@ void RecentFilesMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu > int nPickListMenuItems = ( aHistoryList.getLength() > 99 ) ? 99 : aHistoryList.getLength(); // New vnd.sun.star.popup: command URL to support direct dispatches - const rtl::OUString aCmdPrefix( RTL_CONSTASCII_USTRINGPARAM( "vnd.sun.star.popup:RecentFileList?entry=" )); + const rtl::OUString aCmdPrefix( "vnd.sun.star.popup:RecentFileList?entry=" ); m_aRecentFilesItems.clear(); if (( nPickListMenuItems > 0 ) && !m_bDisabled ) @@ -171,17 +171,17 @@ void RecentFilesMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu > if ( i <= 9 ) { if ( i == 9 ) - aMenuShortCut = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "1~0: " )); + aMenuShortCut = rtl::OUString( "1~0: " ); else { menuShortCut[1] = (char)( '1' + i ); - aMenuShortCut = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( menuShortCut )); + aMenuShortCut = rtl::OUString( menuShortCut ); } } else { aMenuShortCut = rtl::OUString::valueOf((sal_Int32)( i + 1 )); - aMenuShortCut += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ": " )); + aMenuShortCut += rtl::OUString( ": " ); } // Abbreviate URL @@ -296,11 +296,11 @@ void RecentFilesMenuController::executeEntry( sal_Int32 nIndex ) sal_Int32 nSize = 2; aArgsList.realloc(nSize); - aArgsList[0].Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Referer" )); - aArgsList[0].Value = makeAny( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( SFX_REFERER_USER ))); + aArgsList[0].Name = ::rtl::OUString( "Referer" ); + aArgsList[0].Value = makeAny( ::rtl::OUString(SFX_REFERER_USER )); // documents in the picklist will never be opened as templates - aArgsList[1].Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "AsTemplate" )); + aArgsList[1].Name = ::rtl::OUString( "AsTemplate" ); aArgsList[1].Value = makeAny( (sal_Bool) sal_False ); if (!m_aModuleName.isEmpty()) @@ -311,7 +311,7 @@ void RecentFilesMenuController::executeEntry( sal_Int32 nIndex ) aArgsList[nSize-1].Value <<= m_aModuleName; } - xDispatch = xDispatchProvider->queryDispatch( aTargetURL, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_default")), 0 ); + xDispatch = xDispatchProvider->queryDispatch( aTargetURL, ::rtl::OUString("_default"), 0 ); } if ( xDispatch.is() ) @@ -440,7 +440,7 @@ throw( RuntimeException ) sal_Int32 nQueryPart = aURL.Complete.indexOf( '?', m_aBaseURL.getLength() ); if ( nQueryPart > 0 ) { - const rtl::OUString aEntryArgStr( RTL_CONSTASCII_USTRINGPARAM( "entry=" )); + const rtl::OUString aEntryArgStr( "entry=" ); sal_Int32 nEntryArg = aURL.Complete.indexOf( aEntryArgStr, nQueryPart ); sal_Int32 nEntryPos = nEntryArg + aEntryArgStr.getLength(); if (( nEntryArg > 0 ) && ( nEntryPos < aURL.Complete.getLength() )) diff --git a/framework/source/uielement/toolbarmanager.cxx b/framework/source/uielement/toolbarmanager.cxx index 874eca876029..f30f07ec80fe 100644 --- a/framework/source/uielement/toolbarmanager.cxx +++ b/framework/source/uielement/toolbarmanager.cxx @@ -189,7 +189,7 @@ static ::com::sun::star::uno::Reference< ::com::sun::star::frame::XLayoutManager { try { - xPropSet->getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LayoutManager" ))) >>= xLayoutManager; + xPropSet->getPropertyValue( ::rtl::OUString( "LayoutManager" )) >>= xLayoutManager; } catch (const RuntimeException&) { @@ -280,7 +280,7 @@ ToolBarManager::ToolBarManager( const Reference< XMultiServiceFactory >& rServic // enables a menu for clipped items and customization SvtCommandOptions aCmdOptions; sal_uInt16 nMenuType = TOOLBOX_MENUTYPE_CLIPPEDITEMS; - if ( !aCmdOptions.Lookup( SvtCommandOptions::CMDOPTION_DISABLED, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CreateDialog")))) + if ( !aCmdOptions.Lookup( SvtCommandOptions::CMDOPTION_DISABLED, ::rtl::OUString("CreateDialog"))) nMenuType |= TOOLBOX_MENUTYPE_CUSTOMIZE; m_pToolBar->SetCommandHdl( LINK( this, ToolBarManager, Command ) ); @@ -417,9 +417,9 @@ void ToolBarManager::UpdateImageOrientation() Sequence< rtl::OUString > aSeqMirrorCmd; Sequence< rtl::OUString > aSeqRotateCmd; m_xUICommandLabels->getByName( - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( UICOMMANDDESCRIPTION_NAMEACCESS_COMMANDMIRRORIMAGELIST ))) >>= aSeqMirrorCmd; + rtl::OUString( UICOMMANDDESCRIPTION_NAMEACCESS_COMMANDMIRRORIMAGELIST )) >>= aSeqMirrorCmd; m_xUICommandLabels->getByName( - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( UICOMMANDDESCRIPTION_NAMEACCESS_COMMANDROTATEIMAGELIST ))) >>= aSeqRotateCmd; + rtl::OUString( UICOMMANDDESCRIPTION_NAMEACCESS_COMMANDROTATEIMAGELIST )) >>= aSeqRotateCmd; CommandToInfoMap::iterator pIter; for ( i = 0; i < aSeqMirrorCmd.getLength(); i++ ) @@ -472,7 +472,7 @@ void ToolBarManager::UpdateControllers() Reference< XLayoutManager > xLayoutManager; Reference< XPropertySet > xFramePropSet( m_xFrame, UNO_QUERY ); if ( xFramePropSet.is() ) - a = xFramePropSet->getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LayoutManager" ))); + a = xFramePropSet->getPropertyValue( ::rtl::OUString( "LayoutManager" )); a >>= xLayoutManager; Reference< XDockableWindow > xDockable( VCLUnoHelper::GetInterface( m_pToolBar ), UNO_QUERY ); if ( xLayoutManager.is() && xDockable.is() ) @@ -912,7 +912,7 @@ void ToolBarManager::CreateControllers() SvtCommandOptions aCmdOptions; if ( xProps.is() ) - xProps->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "DefaultContext" ))) >>= xComponentContext; + xProps->getPropertyValue( rtl::OUString( "DefaultContext" )) >>= xComponentContext; for ( sal_uInt16 i = 0; i < m_pToolBar->GetItemCount(); i++ ) { @@ -920,7 +920,7 @@ void ToolBarManager::CreateControllers() if ( nId == 0 ) continue; - rtl::OUString aLoadURL( RTL_CONSTASCII_USTRINGPARAM( ".uno:OpenUrl" )); + rtl::OUString aLoadURL( ".uno:OpenUrl" ); rtl::OUString aCommandURL( m_pToolBar->GetItemCommand( nId )); sal_Bool bInit( sal_True ); sal_Bool bCreate( sal_True ); @@ -950,22 +950,22 @@ void ToolBarManager::CreateControllers() PropertyValue aPropValue; std::vector< Any > aPropertyVector; - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ModuleName" )); + aPropValue.Name = rtl::OUString( "ModuleName" ); aPropValue.Value <<= m_aModuleIdentifier; aPropertyVector.push_back( makeAny( aPropValue )); - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Frame" )); + aPropValue.Name = rtl::OUString( "Frame" ); aPropValue.Value <<= m_xFrame; aPropertyVector.push_back( makeAny( aPropValue )); - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ServiceManager" )); + aPropValue.Name = rtl::OUString( "ServiceManager" ); aPropValue.Value <<= m_xServiceManager; aPropertyVector.push_back( makeAny( aPropValue )); - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ParentWindow" )); + aPropValue.Name = rtl::OUString( "ParentWindow" ); aPropValue.Value <<= xToolbarWindow; aPropertyVector.push_back( makeAny( aPropValue )); if ( nWidth > 0 ) { - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Width" )); + aPropValue.Name = rtl::OUString( "Width" ); aPropValue.Value <<= nWidth; aPropertyVector.push_back( makeAny( aPropValue )); } @@ -1060,25 +1060,25 @@ void ToolBarManager::CreateControllers() PropertyValue aPropValue; std::vector< Any > aPropertyVector; - aPropValue.Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Frame" )); + aPropValue.Name = ::rtl::OUString( "Frame" ); aPropValue.Value <<= m_xFrame; aPropertyVector.push_back( makeAny( aPropValue )); - aPropValue.Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "CommandURL" )); + aPropValue.Name = ::rtl::OUString( "CommandURL" ); aPropValue.Value <<= aCommandURL; aPropertyVector.push_back( makeAny( aPropValue )); - aPropValue.Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ServiceManager" )); + aPropValue.Name = ::rtl::OUString( "ServiceManager" ); aPropValue.Value <<= m_xServiceManager; aPropertyVector.push_back( makeAny( aPropValue )); - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ParentWindow" )); + aPropValue.Name = rtl::OUString( "ParentWindow" ); aPropValue.Value <<= xToolbarWindow; aPropertyVector.push_back( makeAny( aPropValue )); - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ModuleName" )); + aPropValue.Name = rtl::OUString( "ModuleName" ); aPropValue.Value <<= m_aModuleIdentifier; aPropertyVector.push_back( makeAny( aPropValue )); if ( nWidth > 0 ) { - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Width" )); + aPropValue.Name = rtl::OUString( "Width" ); aPropValue.Value <<= nWidth; aPropertyVector.push_back( makeAny( aPropValue )); } @@ -1088,10 +1088,10 @@ void ToolBarManager::CreateControllers() if (pController) { - if(aCommandURL == rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:SwitchXFormsDesignMode" )) || - aCommandURL == rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:ViewDataSourceBrowser" )) || - aCommandURL == rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:ParaLeftToRight" )) || - aCommandURL == rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:ParaRightToLeft" )) + if(aCommandURL == rtl::OUString( ".uno:SwitchXFormsDesignMode" ) || + aCommandURL == rtl::OUString( ".uno:ViewDataSourceBrowser" ) || + aCommandURL == rtl::OUString( ".uno:ParaLeftToRight" ) || + aCommandURL == rtl::OUString( ".uno:ParaRightToLeft" ) ) pController->setFastPropertyValue_NoBroadcast(1,makeAny(sal_True)); } @@ -1123,7 +1123,7 @@ void ToolBarManager::CreateControllers() try { sal_Bool bSupportVisible = sal_True; - Any a( xPropSet->getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "SupportsVisible" ))) ); + Any a( xPropSet->getPropertyValue( ::rtl::OUString( "SupportsVisible" )) ); a >>= bSupportVisible; if (bSupportVisible) { @@ -1167,7 +1167,7 @@ void ToolBarManager::AddImageOrientationListener() m_xImageOrientationListener = Reference< XComponent >( static_cast< ::cppu::OWeakObject *>( pImageOrientation ), UNO_QUERY ); pImageOrientation->addStatusListener( - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:ImageOrientation" ))); + rtl::OUString( ".uno:ImageOrientation" )); pImageOrientation->bindListener(); } } @@ -1347,9 +1347,9 @@ void ToolBarManager::FillToolbar( const Reference< XIndexAccess >& rItemContaine ::rtl::OUString sShortCut; if( RetrieveShortcut( aCommandURL, sShortCut ) ) { - sQuickHelp += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( " (" ) ); + sQuickHelp += rtl::OUString( " (" ); sQuickHelp += sShortCut; - sQuickHelp += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ")" ) ); + sQuickHelp += rtl::OUString( ")" ); } m_pToolBar->SetQuickHelpText( nId, sQuickHelp ); @@ -1488,7 +1488,7 @@ void ToolBarManager::FillToolbar( const Reference< XIndexAccess >& rItemContaine try { rtl::OUString aUIName; - xPropSet->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "UIName" ))) >>= aUIName; + xPropSet->getPropertyValue( rtl::OUString( "UIName" )) >>= aUIName; if ( !aUIName.isEmpty() ) m_pToolBar->SetText( aUIName ); } @@ -1733,7 +1733,7 @@ PopupMenu * ToolBarManager::GetToolBarCustomMenu(ToolBox* pToolBar) if ( m_xFrame.is() ) { Reference< XDispatchProvider > xProv( m_xFrame, UNO_QUERY ); - aURL.Complete = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:ConfigureDialog" )); + aURL.Complete = ::rtl::OUString( ".uno:ConfigureDialog" ); m_xURLTransformer->parseStrict( aURL ); if ( xProv.is() ) xDisp = xProv->queryDispatch( aURL, ::rtl::OUString(), 0 ); @@ -1900,7 +1900,7 @@ IMPL_LINK( ToolBarManager, MenuSelect, Menu*, pMenu ) if ( m_xFrame.is() ) { Reference< XDispatchProvider > xProv( m_xFrame, UNO_QUERY ); - aURL.Complete = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:ConfigureDialog" )); + aURL.Complete = ::rtl::OUString( ".uno:ConfigureDialog" ); m_xURLTransformer->parseStrict( aURL ); if ( xProv.is() ) xDisp = xProv->queryDispatch( aURL, ::rtl::OUString(), 0 ); @@ -1911,7 +1911,7 @@ IMPL_LINK( ToolBarManager, MenuSelect, Menu*, pMenu ) Sequence< PropertyValue > aPropSeq( 1 ); aPropSeq[ 0 ].Name = - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("ResourceURL")); + rtl::OUString( "ResourceURL"); aPropSeq[ 0 ].Value <<= m_aResourceName; xDisp->dispatch( aURL, aPropSeq ); @@ -2021,7 +2021,7 @@ IMPL_LINK( ToolBarManager, MenuSelect, Menu*, pMenu ) if ( xPropSet.is() ) { Reference< XUIConfigurationPersistence > xUICfgMgr; - if (( xPropSet->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("ConfigurationSource" ))) >>= xUICfgMgr ) && ( xUICfgMgr.is() )) + if (( xPropSet->getPropertyValue( rtl::OUString( "ConfigurationSource" )) >>= xUICfgMgr ) && ( xUICfgMgr.is() )) xUICfgMgr->store(); } } diff --git a/framework/source/uielement/toolbarsmenucontroller.cxx b/framework/source/uielement/toolbarsmenucontroller.cxx index ca442fb1bb14..78ac6cd37044 100644 --- a/framework/source/uielement/toolbarsmenucontroller.cxx +++ b/framework/source/uielement/toolbarsmenucontroller.cxx @@ -130,7 +130,7 @@ Reference< XLayoutManager > getLayoutManagerFromFrame( const Reference< XFrame > try { - xPropSet->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LayoutManager" ))) >>= xLayoutManager; + xPropSet->getPropertyValue( rtl::OUString( "LayoutManager" )) >>= xLayoutManager; } catch ( const UnknownPropertyException& ) { @@ -155,8 +155,8 @@ DEFINE_INIT_SERVICE ( ToolbarsMenuController, {} ) ToolbarsMenuController::ToolbarsMenuController( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceManager ) : svt::PopupMenuControllerBase( xServiceManager ), - m_aPropUIName( RTL_CONSTASCII_USTRINGPARAM( "UIName" )), - m_aPropResourceURL( RTL_CONSTASCII_USTRINGPARAM( "ResourceURL" )), + m_aPropUIName( "UIName" ), + m_aPropResourceURL( "ResourceURL" ), m_bModuleIdentified( sal_False ), m_bResetActive( sal_False ), m_aIntlWrapper( xServiceManager, Application::GetSettings().GetLocale() ) @@ -182,7 +182,7 @@ void ToolbarsMenuController::addCommand( Reference< awt::XMenuExtended > xMenuExtended( m_xPopupMenu, UNO_QUERY ); xMenuExtended->setCommand( nItemId, rCommandURL ); - bool bInternal = ( rCommandURL.indexOf( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( STATIC_INTERNAL_CMD_PART ))) == 0); + bool bInternal = ( rCommandURL.indexOf( rtl::OUString( STATIC_INTERNAL_CMD_PART )) == 0); if ( !bInternal ) { if ( !getDispatchFromCommandURL( rCommandURL ).is() ) @@ -315,8 +315,8 @@ Sequence< Sequence< com::sun::star::beans::PropertyValue > > ToolbarsMenuControl { rtl::OUString aResName; sal_Int16 nType( -1 ); - xPropSet->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Type" ))) >>= nType; - xPropSet->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ResourceURL" ))) >>= aResName; + xPropSet->getPropertyValue( rtl::OUString( "Type" )) >>= nType; + xPropSet->getPropertyValue( rtl::OUString( "ResourceURL" )) >>= aResName; if (( nType == ::com::sun::star::ui::UIElementType::TOOLBAR ) && !aResName.isEmpty() ) @@ -396,7 +396,7 @@ void ToolbarsMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu >& r } std::vector< ToolBarEntry > aSortedTbs; - rtl::OUString aStaticCmdPart( RTL_CONSTASCII_USTRINGPARAM( STATIC_CMD_PART )); + rtl::OUString aStaticCmdPart( STATIC_CMD_PART ); Sequence< Sequence< com::sun::star::beans::PropertyValue > > aSeqFrameToolBars = getLayoutManagerToolbars( xLayoutManager ); fillHashMap( aSeqFrameToolBars, aToolbarHashMap ); @@ -499,21 +499,21 @@ void ToolbarsMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu >& r { if ( m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.DrawingDocument" ) ) || m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.PresentationDocument" ) )) - addCommand( m_xPopupMenu, rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CMD_COLORBAR )), aEmptyString ); + addCommand( m_xPopupMenu, rtl::OUString( CMD_COLORBAR ), aEmptyString ); else if ( m_aModuleIdentifier == "com.sun.star.sheet.SpreadsheetDocument" ) - addCommand( m_xPopupMenu, rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CMD_INPUTLINEBAR )), aEmptyString ); + addCommand( m_xPopupMenu, rtl::OUString( CMD_INPUTLINEBAR ), aEmptyString ); else - addCommand( m_xPopupMenu, rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CMD_FORMULABAR )), aEmptyString ); + addCommand( m_xPopupMenu, rtl::OUString( CMD_FORMULABAR ), aEmptyString ); } sal_Bool bAddCommand( sal_True ); SvtCommandOptions aCmdOptions; - rtl::OUString aConfigureToolbar( RTL_CONSTASCII_USTRINGPARAM( CONFIGURE_TOOLBARS )); + rtl::OUString aConfigureToolbar( CONFIGURE_TOOLBARS ); if ( aCmdOptions.HasEntries( SvtCommandOptions::CMDOPTION_DISABLED )) { if ( aCmdOptions.Lookup( SvtCommandOptions::CMDOPTION_DISABLED, - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CONFIGURE_TOOLBARS_CMD )))) + rtl::OUString( CONFIGURE_TOOLBARS_CMD ))) bAddCommand = sal_False; } @@ -541,7 +541,7 @@ void ToolbarsMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu >& r } String aLabelStr = String( FwkResId( STR_RESTORE_TOOLBARS )); - rtl::OUString aRestoreCmd( RTL_CONSTASCII_USTRINGPARAM( CMD_RESTOREVISIBILITY )); + rtl::OUString aRestoreCmd( CMD_RESTOREVISIBILITY ); addCommand( m_xPopupMenu, aRestoreCmd, aLabelStr ); } } @@ -638,7 +638,7 @@ void SAL_CALL ToolbarsMenuController::select( const css::awt::MenuEvent& rEvent PopupMenu* pVCLPopupMenu = (PopupMenu *)pPopupMenu->GetMenu(); rtl::OUString aCmd( pVCLPopupMenu->GetItemCommand( rEvent.MenuId )); - if ( aCmd.indexOf( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( STATIC_INTERNAL_CMD_PART ))) == 0 ) + if ( aCmd.indexOf( rtl::OUString( STATIC_INTERNAL_CMD_PART )) == 0 ) { // Command to restore the visibility of all context sensitive toolbars Reference< XNameReplace > xNameReplace( xPersistentWindowState, UNO_QUERY ); @@ -697,7 +697,7 @@ void SAL_CALL ToolbarsMenuController::select( const css::awt::MenuEvent& rEvent { try { - xPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "RefreshContextToolbarVisibility" )), makeAny( sal_True )); + xPropSet->setPropertyValue( rtl::OUString( "RefreshContextToolbarVisibility" ), makeAny( sal_True )); } catch ( const RuntimeException& ) { @@ -719,7 +719,7 @@ void SAL_CALL ToolbarsMenuController::select( const css::awt::MenuEvent& rEvent } } } - else if ( aCmd.indexOf( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( STATIC_CMD_PART ))) < 0 ) + else if ( aCmd.indexOf( rtl::OUString( STATIC_CMD_PART )) < 0 ) { URL aTargetURL; Sequence<PropertyValue> aArgs; @@ -748,7 +748,7 @@ void SAL_CALL ToolbarsMenuController::select( const css::awt::MenuEvent& rEvent sal_Int32 nIndex = aCmd.indexOf( '=' ); if (( nIndex > 0 ) && (( nIndex+1 ) < aCmd.getLength() )) { - rtl::OUStringBuffer aBuf( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( STATIC_PRIVATE_TB_RESOURCE ))); + rtl::OUStringBuffer aBuf( rtl::OUString( STATIC_PRIVATE_TB_RESOURCE )); aBuf.append( aCmd.copy( nIndex+1 )); sal_Bool bShow( !pVCLPopupMenu->IsItemChecked( rEvent.MenuId )); @@ -787,7 +787,7 @@ void SAL_CALL ToolbarsMenuController::activate( const css::awt::MenuEvent& ) thr const sal_uInt32 nCount = aCmdVector.size(); for ( sal_uInt32 i = 0; i < nCount; i++ ) { - bool bInternal = ( aCmdVector[i].indexOf( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( STATIC_INTERNAL_CMD_PART ))) == 0); + bool bInternal = ( aCmdVector[i].indexOf( rtl::OUString( STATIC_INTERNAL_CMD_PART )) == 0); if ( !bInternal ) { diff --git a/framework/source/uielement/uicommanddescription.cxx b/framework/source/uielement/uicommanddescription.cxx index 3cd314c8eda7..95c03e00af37 100644 --- a/framework/source/uielement/uicommanddescription.cxx +++ b/framework/source/uielement/uicommanddescription.cxx @@ -208,15 +208,15 @@ class ConfigurationAccess_UICommand : // Order is neccessary for right initializ //***************************************************************************************************************** ConfigurationAccess_UICommand::ConfigurationAccess_UICommand( const rtl::OUString& aModuleName, const Reference< XNameAccess >& rGenericUICommands, const Reference< XMultiServiceFactory >& rServiceManager ) : ThreadHelpBase(), - m_aConfigCmdAccess( RTL_CONSTASCII_USTRINGPARAM( CONFIGURATION_ROOT_ACCESS )), - m_aConfigPopupAccess( RTL_CONSTASCII_USTRINGPARAM( CONFIGURATION_ROOT_ACCESS )), - m_aPropUILabel( RTL_CONSTASCII_USTRINGPARAM( CONFIGURATION_PROPERTY_LABEL )), - m_aPropUIContextLabel( RTL_CONSTASCII_USTRINGPARAM( CONFIGURATION_PROPERTY_CONTEXT_LABEL )), - m_aPropLabel( RTL_CONSTASCII_USTRINGPARAM( PROPSET_LABEL )), - m_aPropName( RTL_CONSTASCII_USTRINGPARAM( PROPSET_NAME )), - m_aPropPopup( RTL_CONSTASCII_USTRINGPARAM( PROPSET_POPUP )), - m_aPropProperties( RTL_CONSTASCII_USTRINGPARAM( PROPSET_PROPERTIES )), - m_aPrivateResourceURL( RTL_CONSTASCII_USTRINGPARAM( PRIVATE_RESOURCE_URL )), + m_aConfigCmdAccess( CONFIGURATION_ROOT_ACCESS ), + m_aConfigPopupAccess( CONFIGURATION_ROOT_ACCESS ), + m_aPropUILabel( CONFIGURATION_PROPERTY_LABEL ), + m_aPropUIContextLabel( CONFIGURATION_PROPERTY_CONTEXT_LABEL ), + m_aPropLabel( PROPSET_LABEL ), + m_aPropName( PROPSET_NAME ), + m_aPropPopup( PROPSET_POPUP ), + m_aPropProperties( PROPSET_PROPERTIES ), + m_aPrivateResourceURL( PRIVATE_RESOURCE_URL ), m_xGenericUICommands( rGenericUICommands ), m_xServiceManager( rServiceManager ), m_bConfigAccessInitialized( sal_False ), @@ -225,12 +225,12 @@ ConfigurationAccess_UICommand::ConfigurationAccess_UICommand( const rtl::OUStrin { // Create configuration hierachical access name m_aConfigCmdAccess += aModuleName; - m_aConfigCmdAccess += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CONFIGURATION_CMD_ELEMENT_ACCESS )); + m_aConfigCmdAccess += rtl::OUString( CONFIGURATION_CMD_ELEMENT_ACCESS ); m_xConfigProvider = Reference< XMultiServiceFactory >( rServiceManager->createInstance(SERVICENAME_CFGPROVIDER),UNO_QUERY ); m_aConfigPopupAccess += aModuleName; - m_aConfigPopupAccess += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CONFIGURATION_POP_ELEMENT_ACCESS )); + m_aConfigPopupAccess += rtl::OUString( CONFIGURATION_POP_ELEMENT_ACCESS ); } ConfigurationAccess_UICommand::~ConfigurationAccess_UICommand() @@ -425,7 +425,7 @@ sal_Bool ConfigurationAccess_UICommand::addGenericInfoToCache() try { if ( m_xGenericUICommands->getByName( - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( UICOMMANDDESCRIPTION_NAMEACCESS_COMMANDROTATEIMAGELIST ))) >>= aCommandNameSeq ) + rtl::OUString( UICOMMANDDESCRIPTION_NAMEACCESS_COMMANDROTATEIMAGELIST )) >>= aCommandNameSeq ) m_aCommandRotateImageList = comphelper::concatSequences< rtl::OUString >( m_aCommandRotateImageList, aCommandNameSeq ); } catch (const RuntimeException&) @@ -439,7 +439,7 @@ sal_Bool ConfigurationAccess_UICommand::addGenericInfoToCache() try { if ( m_xGenericUICommands->getByName( - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( UICOMMANDDESCRIPTION_NAMEACCESS_COMMANDMIRRORIMAGELIST ))) >>= aCommandNameSeq ) + rtl::OUString( UICOMMANDDESCRIPTION_NAMEACCESS_COMMANDMIRRORIMAGELIST )) >>= aCommandNameSeq ) m_aCommandMirrorImageList = comphelper::concatSequences< rtl::OUString >( m_aCommandMirrorImageList, aCommandNameSeq ); } catch (const RuntimeException&) @@ -546,7 +546,7 @@ sal_Bool ConfigurationAccess_UICommand::initializeConfigAccess() try { - aPropValue.Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "nodepath" )); + aPropValue.Name = rtl::OUString( "nodepath" ); aPropValue.Value <<= m_aConfigCmdAccess; aArgs[0] <<= aPropValue; @@ -642,12 +642,12 @@ DEFINE_INIT_SERVICE ( UICommandDescription, {} ) UICommandDescription::UICommandDescription( const Reference< XMultiServiceFactory >& xServiceManager ) : ThreadHelpBase(), - m_aPrivateResourceURL( RTL_CONSTASCII_USTRINGPARAM( PRIVATE_RESOURCE_URL )), + m_aPrivateResourceURL( PRIVATE_RESOURCE_URL ), m_xServiceManager( xServiceManager ) { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "framework", "Ocke.Janssen@sun.com", "UICommandDescription::UICommandDescription" ); Reference< XNameAccess > xEmpty; - rtl::OUString aGenericUICommand( RTL_CONSTASCII_USTRINGPARAM("GenericCommands") ); + rtl::OUString aGenericUICommand( "GenericCommands" ); m_xGenericUICommands = new ConfigurationAccess_UICommand( aGenericUICommand, xEmpty, xServiceManager ); impl_fillElements("ooSetupFactoryCommandConfigRef"); diff --git a/framework/source/xml/acceleratorconfigurationwriter.cxx b/framework/source/xml/acceleratorconfigurationwriter.cxx index a3e0fe4e3c95..9d1a9748addd 100644 --- a/framework/source/xml/acceleratorconfigurationwriter.cxx +++ b/framework/source/xml/acceleratorconfigurationwriter.cxx @@ -134,16 +134,16 @@ void AcceleratorConfigurationWriter::impl_ts_writeKeyCommandPair(const css::awt: pAttribs->AddAttribute(AL_ATTRIBUTE_URL , ATTRIBUTE_TYPE_CDATA, sCommand); if ((aKey.Modifiers & css::awt::KeyModifier::SHIFT) == css::awt::KeyModifier::SHIFT) - pAttribs->AddAttribute(AL_ATTRIBUTE_MOD_SHIFT, ATTRIBUTE_TYPE_CDATA, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("true"))); + pAttribs->AddAttribute(AL_ATTRIBUTE_MOD_SHIFT, ATTRIBUTE_TYPE_CDATA, ::rtl::OUString("true")); if ((aKey.Modifiers & css::awt::KeyModifier::MOD1) == css::awt::KeyModifier::MOD1) - pAttribs->AddAttribute(AL_ATTRIBUTE_MOD_MOD1, ATTRIBUTE_TYPE_CDATA, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("true"))); + pAttribs->AddAttribute(AL_ATTRIBUTE_MOD_MOD1, ATTRIBUTE_TYPE_CDATA, ::rtl::OUString("true")); if ((aKey.Modifiers & css::awt::KeyModifier::MOD2) == css::awt::KeyModifier::MOD2) - pAttribs->AddAttribute(AL_ATTRIBUTE_MOD_MOD2, ATTRIBUTE_TYPE_CDATA, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("true"))); + pAttribs->AddAttribute(AL_ATTRIBUTE_MOD_MOD2, ATTRIBUTE_TYPE_CDATA, ::rtl::OUString("true")); if ((aKey.Modifiers & css::awt::KeyModifier::MOD3) == css::awt::KeyModifier::MOD3) - pAttribs->AddAttribute(AL_ATTRIBUTE_MOD_MOD3, ATTRIBUTE_TYPE_CDATA, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("true"))); + pAttribs->AddAttribute(AL_ATTRIBUTE_MOD_MOD3, ATTRIBUTE_TYPE_CDATA, ::rtl::OUString("true")); xConfig->ignorableWhitespace(::rtl::OUString()); xConfig->startElement(AL_ELEMENT_ITEM, xAttribs); |