summaryrefslogtreecommitdiff
path: root/framework
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-11-06 12:32:17 +0100
committerStephan Bergmann <sbergman@redhat.com>2015-11-06 12:32:17 +0100
commitc5376ef685e275f35781a99a37bdf6d13451c015 (patch)
tree0173e1b3709cadd4c8ffd0ba96a6bf777c579f7f /framework
parent7bad24feed2c82bdeaf4b6e0b4c900d9e729953f (diff)
loplugin:stringconstant: elide explicit ctor usage (manually due to macros)
Change-Id: I4633229b94be1b15dfa14eafe8d7176a1fd253c9
Diffstat (limited to 'framework')
-rw-r--r--framework/inc/properties.h11
-rw-r--r--framework/source/fwe/helper/titlehelper.cxx2
-rw-r--r--framework/source/helper/titlebarupdate.cxx4
-rw-r--r--framework/source/layoutmanager/layoutmanager.cxx10
-rw-r--r--framework/source/loadenv/loadenv.cxx4
5 files changed, 10 insertions, 21 deletions
diff --git a/framework/inc/properties.h b/framework/inc/properties.h
index 7faa55a21f9d..5f0947d891a0 100644
--- a/framework/inc/properties.h
+++ b/framework/inc/properties.h
@@ -100,11 +100,6 @@ namespace framework{
#define LAYOUTMANAGER_PROPNAME_ASCII_PRESERVE_CONTENT_SIZE "PreserveContentSize"
#define LAYOUTMANAGER_PROPNAME_MENUBARCLOSER LAYOUTMANAGER_PROPNAME_ASCII_MENUBARCLOSER
-#define LAYOUTMANAGER_PROPNAME_AUTOMATICTOOLBARS OUString( LAYOUTMANAGER_PROPNAME_ASCII_AUTOMATICTOOLBARS )
-#define LAYOUTMANAGER_PROPNAME_REFRESHVISIBILITY OUString( LAYOUTMANAGER_PROPNAME_ASCII_REFRESHVISIBILITY )
-#define LAYOUTMANAGER_PROPNAME_HIDECURRENTUI OUString( LAYOUTMANAGER_PROPNAME_ASCII_HIDECURRENTUI )
-#define LAYOUTMANAGER_PROPNAME_LOCKCOUNT OUString( LAYOUTMANAGER_PROPNAME_ASCII_LOCKCOUNT )
-#define LAYOUTMANAGER_PROPNAME_PRESERVE_CONTENT_SIZE OUString( LAYOUTMANAGER_PROPNAME_ASCII_PRESERVE_CONTENT_SIZE )
#define LAYOUTMANAGER_PROPHANDLE_MENUBARCLOSER 0
#define LAYOUTMANAGER_PROPHANDLE_AUTOMATICTOOLBARS 1
@@ -141,18 +136,12 @@ namespace framework{
#define FILTER_PROPNAME_ASCII_DOCUMENTSERVICE "DocumentService"
-#define FILTER_PROPNAME_DOCUMENTSERVICE OUString( FILTER_PROPNAME_ASCII_DOCUMENTSERVICE )
-
/** properties for office module config (Setup.xcu) */
#define OFFICEFACTORY_PROPNAME_ASCII_WINDOWATTRIBUTES "ooSetupFactoryWindowAttributes"
#define OFFICEFACTORY_PROPNAME_ASCII_UINAME "ooSetupFactoryUIName"
#define OFFICEFACTORY_PROPNAME_ASCII_ICON "ooSetupFactoryIcon"
-#define OFFICEFACTORY_PROPNAME_WINDOWATTRIBUTES OUString( OFFICEFACTORY_PROPNAME_ASCII_WINDOWATTRIBUTES )
-#define OFFICEFACTORY_PROPNAME_UINAME OUString( OFFICEFACTORY_PROPNAME_ASCII_UINAME )
-#define OFFICEFACTORY_PROPNAME_ICON OUString( OFFICEFACTORY_PROPNAME_ASCII_ICON )
-
/** properties for tab window (old) */
#define TABWINDOW_PROPNAME_ASCII_PARENTWINDOW "ParentWindow"
#define TABWINDOW_PROPNAME_ASCII_TOPWINDOW "TopWindow"
diff --git a/framework/source/fwe/helper/titlehelper.cxx b/framework/source/fwe/helper/titlehelper.cxx
index bbd8d95843eb..c9aba3e5b2e7 100644
--- a/framework/source/fwe/helper/titlehelper.cxx
+++ b/framework/source/fwe/helper/titlehelper.cxx
@@ -542,7 +542,7 @@ void TitleHelper::impl_appendModuleName (OUStringBuffer& sTitle)
const OUString sID = xModuleManager->identify(xOwner);
::comphelper::SequenceAsHashMap lProps = xModuleManager->getByName (sID);
- const OUString sUIName = lProps.getUnpackedValueOrDefault (OFFICEFACTORY_PROPNAME_UINAME, OUString());
+ const OUString sUIName = lProps.getUnpackedValueOrDefault (OFFICEFACTORY_PROPNAME_ASCII_UINAME, OUString());
// An UIname property is an optional value !
// So please add it to the title in case it does really exists only.
diff --git a/framework/source/helper/titlebarupdate.cxx b/framework/source/helper/titlebarupdate.cxx
index 6362b5a51258..99d8b563444d 100644
--- a/framework/source/helper/titlebarupdate.cxx
+++ b/framework/source/helper/titlebarupdate.cxx
@@ -196,8 +196,8 @@ bool TitleBarUpdate::implst_getModuleInfo(const css::uno::Reference< css::frame:
rInfo.sID = xModuleManager->identify(xFrame);
::comphelper::SequenceAsHashMap lProps = xModuleManager->getByName (rInfo.sID);
- rInfo.sUIName = lProps.getUnpackedValueOrDefault (OFFICEFACTORY_PROPNAME_UINAME, OUString());
- rInfo.nIcon = lProps.getUnpackedValueOrDefault (OFFICEFACTORY_PROPNAME_ICON , INVALID_ICON_ID );
+ rInfo.sUIName = lProps.getUnpackedValueOrDefault (OFFICEFACTORY_PROPNAME_ASCII_UINAME, OUString());
+ rInfo.nIcon = lProps.getUnpackedValueOrDefault (OFFICEFACTORY_PROPNAME_ASCII_ICON , INVALID_ICON_ID );
// Note: If we could retrieve a module id ... everything is OK.
// UIName and Icon ID are optional values !
diff --git a/framework/source/layoutmanager/layoutmanager.cxx b/framework/source/layoutmanager/layoutmanager.cxx
index 150c12a413ce..d7928383e189 100644
--- a/framework/source/layoutmanager/layoutmanager.cxx
+++ b/framework/source/layoutmanager/layoutmanager.cxx
@@ -148,12 +148,12 @@ LayoutManager::LayoutManager( const Reference< XComponentContext >& xContext ) :
m_aAsyncLayoutTimer.SetTimeout( 50 );
m_aAsyncLayoutTimer.SetTimeoutHdl( LINK( this, LayoutManager, AsyncLayoutHdl ) );
- registerProperty( LAYOUTMANAGER_PROPNAME_AUTOMATICTOOLBARS, LAYOUTMANAGER_PROPHANDLE_AUTOMATICTOOLBARS, css::beans::PropertyAttribute::TRANSIENT, &m_bAutomaticToolbars, cppu::UnoType<decltype(m_bAutomaticToolbars)>::get() );
- registerProperty( LAYOUTMANAGER_PROPNAME_HIDECURRENTUI, LAYOUTMANAGER_PROPHANDLE_HIDECURRENTUI, beans::PropertyAttribute::TRANSIENT, &m_bHideCurrentUI, cppu::UnoType<decltype(m_bHideCurrentUI)>::get() );
- registerProperty( LAYOUTMANAGER_PROPNAME_LOCKCOUNT, LAYOUTMANAGER_PROPHANDLE_LOCKCOUNT, beans::PropertyAttribute::TRANSIENT | beans::PropertyAttribute::READONLY, &m_nLockCount, cppu::UnoType<decltype(m_nLockCount)>::get() );
+ registerProperty( LAYOUTMANAGER_PROPNAME_ASCII_AUTOMATICTOOLBARS, LAYOUTMANAGER_PROPHANDLE_AUTOMATICTOOLBARS, css::beans::PropertyAttribute::TRANSIENT, &m_bAutomaticToolbars, cppu::UnoType<decltype(m_bAutomaticToolbars)>::get() );
+ registerProperty( LAYOUTMANAGER_PROPNAME_ASCII_HIDECURRENTUI, LAYOUTMANAGER_PROPHANDLE_HIDECURRENTUI, beans::PropertyAttribute::TRANSIENT, &m_bHideCurrentUI, cppu::UnoType<decltype(m_bHideCurrentUI)>::get() );
+ registerProperty( LAYOUTMANAGER_PROPNAME_ASCII_LOCKCOUNT, LAYOUTMANAGER_PROPHANDLE_LOCKCOUNT, beans::PropertyAttribute::TRANSIENT | beans::PropertyAttribute::READONLY, &m_nLockCount, cppu::UnoType<decltype(m_nLockCount)>::get() );
registerProperty( LAYOUTMANAGER_PROPNAME_MENUBARCLOSER, LAYOUTMANAGER_PROPHANDLE_MENUBARCLOSER, beans::PropertyAttribute::TRANSIENT, &m_bMenuBarCloseButton, cppu::UnoType<decltype(m_bMenuBarCloseButton)>::get() );
- registerPropertyNoMember( LAYOUTMANAGER_PROPNAME_REFRESHVISIBILITY, LAYOUTMANAGER_PROPHANDLE_REFRESHVISIBILITY, beans::PropertyAttribute::TRANSIENT, cppu::UnoType<decltype(bRefreshVisibility)>::get(), &bRefreshVisibility );
- registerProperty( LAYOUTMANAGER_PROPNAME_PRESERVE_CONTENT_SIZE, LAYOUTMANAGER_PROPHANDLE_PRESERVE_CONTENT_SIZE, beans::PropertyAttribute::TRANSIENT, &m_bPreserveContentSize, cppu::UnoType<decltype(m_bPreserveContentSize)>::get() );
+ registerPropertyNoMember( LAYOUTMANAGER_PROPNAME_ASCII_REFRESHVISIBILITY, LAYOUTMANAGER_PROPHANDLE_REFRESHVISIBILITY, beans::PropertyAttribute::TRANSIENT, cppu::UnoType<decltype(bRefreshVisibility)>::get(), &bRefreshVisibility );
+ registerProperty( LAYOUTMANAGER_PROPNAME_ASCII_PRESERVE_CONTENT_SIZE, LAYOUTMANAGER_PROPHANDLE_PRESERVE_CONTENT_SIZE, beans::PropertyAttribute::TRANSIENT, &m_bPreserveContentSize, cppu::UnoType<decltype(m_bPreserveContentSize)>::get() );
}
LayoutManager::~LayoutManager()
diff --git a/framework/source/loadenv/loadenv.cxx b/framework/source/loadenv/loadenv.cxx
index a9183a8fa745..57e572e78335 100644
--- a/framework/source/loadenv/loadenv.cxx
+++ b/framework/source/loadenv/loadenv.cxx
@@ -1713,7 +1713,7 @@ void LoadEnv::impl_applyPersistentWindowState(const css::uno::Reference< css::aw
xContext->getServiceManager()->createInstanceWithContext(SERVICENAME_FILTERFACTORY, xContext),
css::uno::UNO_QUERY_THROW);
::comphelper::SequenceAsHashMap lProps (xFilterCfg->getByName(sFilter));
- OUString sModule = lProps.getUnpackedValueOrDefault(FILTER_PROPNAME_DOCUMENTSERVICE, OUString());
+ OUString sModule = lProps.getUnpackedValueOrDefault(FILTER_PROPNAME_ASCII_DOCUMENTSERVICE, OUString());
// get access to the configuration of this office module
css::uno::Reference< css::container::XNameAccess > xModuleCfg(::comphelper::ConfigurationHelper::openConfig(
@@ -1726,7 +1726,7 @@ void LoadEnv::impl_applyPersistentWindowState(const css::uno::Reference< css::aw
// and apply it on the window.
// Do nothing, if no configuration entry exists!
OUString sWindowState;
- ::comphelper::ConfigurationHelper::readRelativeKey(xModuleCfg, sModule, OFFICEFACTORY_PROPNAME_WINDOWATTRIBUTES) >>= sWindowState;
+ ::comphelper::ConfigurationHelper::readRelativeKey(xModuleCfg, sModule, OFFICEFACTORY_PROPNAME_ASCII_WINDOWATTRIBUTES) >>= sWindowState;
if (!sWindowState.isEmpty())
{
// SOLAR SAFE ->