diff options
author | Olivier Hallot <olivier.hallot@alta.org.br> | 2012-04-06 08:27:05 -0300 |
---|---|---|
committer | Olivier Hallot <olivier.hallot@alta.org.br> | 2012-04-06 08:33:34 -0300 |
commit | 7d82fb18fe6ae68f6eb6a33c6030105f9e2fe232 (patch) | |
tree | 21f0241197e5987e5bee788e759e06d083a5c1fb /sd | |
parent | 501e290b8eb86a31e936e210aeb76d0b8c1a12b3 (diff) |
Review of some RTL_CONSTASCII_USTRINGPARAM removal
Remove OUString constructor where not needed.
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/ui/view/Outliner.cxx | 3 | ||||
-rw-r--r-- | sd/source/ui/view/PresentationViewShellBase.cxx | 8 | ||||
-rw-r--r-- | sd/source/ui/view/ToolBarManager.cxx | 38 | ||||
-rw-r--r-- | sd/source/ui/view/ViewShellBase.cxx | 8 | ||||
-rw-r--r-- | sd/source/ui/view/drviews7.cxx | 3 | ||||
-rw-r--r-- | sd/source/ui/view/drviewsa.cxx | 5 | ||||
-rw-r--r-- | sd/source/ui/view/drviewsb.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/view/drviewse.cxx | 20 |
8 files changed, 37 insertions, 50 deletions
diff --git a/sd/source/ui/view/Outliner.cxx b/sd/source/ui/view/Outliner.cxx index d9858b15f897..e7100e7f1759 100644 --- a/sd/source/ui/view/Outliner.cxx +++ b/sd/source/ui/view/Outliner.cxx @@ -211,8 +211,7 @@ Outliner::Outliner( SdDrawDocument* pDoc, sal_uInt16 nMode ) const SvtLinguConfig aLinguConfig; Any aAny; - aAny = aLinguConfig.GetProperty( - rtl::OUString( UPN_IS_SPELL_AUTO ) ); + aAny = aLinguConfig.GetProperty( UPN_IS_SPELL_AUTO ); aAny >>= bOnlineSpell; } catch( ... ) diff --git a/sd/source/ui/view/PresentationViewShellBase.cxx b/sd/source/ui/view/PresentationViewShellBase.cxx index 8c7315f24f64..bd431606101a 100644 --- a/sd/source/ui/view/PresentationViewShellBase.cxx +++ b/sd/source/ui/view/PresentationViewShellBase.cxx @@ -85,14 +85,10 @@ PresentationViewShellBase::PresentationViewShellBase ( UNO_QUERY); if (xFrameSet.is()) { - Reference<beans::XPropertySet> xLayouterSet ( - xFrameSet->getPropertyValue(::rtl::OUString("LayoutManager")), - UNO_QUERY); + Reference<beans::XPropertySet> xLayouterSet(xFrameSet->getPropertyValue("LayoutManager"), UNO_QUERY); if (xLayouterSet.is()) { - xLayouterSet->setPropertyValue( - ::rtl::OUString("AutomaticToolbars"), - makeAny(sal_False)); + xLayouterSet->setPropertyValue("AutomaticToolbars", makeAny(sal_False)); } } } diff --git a/sd/source/ui/view/ToolBarManager.cxx b/sd/source/ui/view/ToolBarManager.cxx index 4d1ef8987f89..7b89cf5f6e58 100644 --- a/sd/source/ui/view/ToolBarManager.cxx +++ b/sd/source/ui/view/ToolBarManager.cxx @@ -58,9 +58,6 @@ using namespace ::com::sun::star; using namespace ::com::sun::star::uno; -#undef OUSTRING // Remove definition made in the SFX -#define OUSTRING(s) (::rtl::OUString(s)) - namespace { using namespace sd; @@ -359,21 +356,21 @@ private: //===== ToolBarManager ======================================================== -const ::rtl::OUString ToolBarManager::msToolBar(OUSTRING("toolbar")); -const ::rtl::OUString ToolBarManager::msOptionsToolBar(OUSTRING("optionsbar")); -const ::rtl::OUString ToolBarManager::msCommonTaskToolBar(OUSTRING("commontaskbar")); -const ::rtl::OUString ToolBarManager::msViewerToolBar(OUSTRING("viewerbar")); -const ::rtl::OUString ToolBarManager::msSlideSorterToolBar(OUSTRING("slideviewtoolbar")); -const ::rtl::OUString ToolBarManager::msSlideSorterObjectBar(OUSTRING("slideviewobjectbar")); -const ::rtl::OUString ToolBarManager::msOutlineToolBar(OUSTRING("outlinetoolbar")); -const ::rtl::OUString ToolBarManager::msMasterViewToolBar(OUSTRING("masterviewtoolbar")); -const ::rtl::OUString ToolBarManager::msDrawingObjectToolBar(OUSTRING("drawingobjectbar")); -const ::rtl::OUString ToolBarManager::msGluePointsToolBar(OUSTRING("gluepointsobjectbar")); -const ::rtl::OUString ToolBarManager::msTextObjectBar(OUSTRING("textobjectbar")); -const ::rtl::OUString ToolBarManager::msBezierObjectBar(OUSTRING("bezierobjectbar")); -const ::rtl::OUString ToolBarManager::msGraphicObjectBar(OUSTRING("graphicobjectbar")); -const ::rtl::OUString ToolBarManager::msMediaObjectBar(OUSTRING("mediaobjectbar")); -const ::rtl::OUString ToolBarManager::msTableObjectBar(OUSTRING("tableobjectbar")); +const ::rtl::OUString ToolBarManager::msToolBar("toolbar"); +const ::rtl::OUString ToolBarManager::msOptionsToolBar("optionsbar"); +const ::rtl::OUString ToolBarManager::msCommonTaskToolBar("commontaskbar"); +const ::rtl::OUString ToolBarManager::msViewerToolBar("viewerbar"); +const ::rtl::OUString ToolBarManager::msSlideSorterToolBar("slideviewtoolbar"); +const ::rtl::OUString ToolBarManager::msSlideSorterObjectBar("slideviewobjectbar"); +const ::rtl::OUString ToolBarManager::msOutlineToolBar("outlinetoolbar"); +const ::rtl::OUString ToolBarManager::msMasterViewToolBar("masterviewtoolbar"); +const ::rtl::OUString ToolBarManager::msDrawingObjectToolBar("drawingobjectbar"); +const ::rtl::OUString ToolBarManager::msGluePointsToolBar("gluepointsobjectbar"); +const ::rtl::OUString ToolBarManager::msTextObjectBar("textobjectbar"); +const ::rtl::OUString ToolBarManager::msBezierObjectBar("bezierobjectbar"); +const ::rtl::OUString ToolBarManager::msGraphicObjectBar("graphicobjectbar"); +const ::rtl::OUString ToolBarManager::msMediaObjectBar("mediaobjectbar"); +const ::rtl::OUString ToolBarManager::msTableObjectBar("tableobjectbar"); ::boost::shared_ptr<ToolBarManager> ToolBarManager::Create ( @@ -597,8 +594,7 @@ void ToolBarManager::ToolBarsDestroyed(void) //===== ToolBarManager::Implementation ======================================= -const ::rtl::OUString ToolBarManager::Implementation::msToolBarResourcePrefix( - OUSTRING("private:resource/toolbar/")); +const ::rtl::OUString ToolBarManager::Implementation::msToolBarResourcePrefix("private:resource/toolbar/"); ToolBarManager::Implementation::Implementation ( ViewShellBase& rBase, @@ -673,7 +669,7 @@ void ToolBarManager::Implementation::SetValid (bool bValid) try { Reference<beans::XPropertySet> xFrameProperties (xFrame, UNO_QUERY_THROW); - Any aValue (xFrameProperties->getPropertyValue(OUSTRING("LayoutManager"))); + Any aValue (xFrameProperties->getPropertyValue("LayoutManager")); aValue >>= mxLayouter; } catch (const RuntimeException&) diff --git a/sd/source/ui/view/ViewShellBase.cxx b/sd/source/ui/view/ViewShellBase.cxx index 340881b7708d..4a8107a2ee46 100644 --- a/sd/source/ui/view/ViewShellBase.cxx +++ b/sd/source/ui/view/ViewShellBase.cxx @@ -1142,14 +1142,14 @@ void ViewShellBase::SetViewTabBar (const ::rtl::Reference<ViewTabBar>& rViewTabB { Reference< XMultiServiceFactory > xServiceManager( ::comphelper::getProcessServiceFactory(), UNO_QUERY_THROW ); - Reference< XModuleManager > xModuleManager( xServiceManager->createInstance( OUString( "com.sun.star.frame.ModuleManager") ), UNO_QUERY_THROW ); + Reference< XModuleManager > xModuleManager( xServiceManager->createInstance( "com.sun.star.frame.ModuleManager" ), UNO_QUERY_THROW ); Reference< XInterface > xIfac( xFrame, UNO_QUERY_THROW ); ::rtl::OUString aModuleIdentifier( xModuleManager->identify( xIfac ) ); if( !aModuleIdentifier.isEmpty() ) { - Reference< XNameAccess > xNameAccess( xServiceManager->createInstance( rtl::OUString( "com.sun.star.frame.UICommandDescription" ) ), UNO_QUERY ); + Reference< XNameAccess > xNameAccess( xServiceManager->createInstance( "com.sun.star.frame.UICommandDescription" ), UNO_QUERY ); if( xNameAccess.is() ) { Reference< ::com::sun::star::container::XNameAccess > m_xUICommandLabels( xNameAccess->getByName( aModuleIdentifier ), UNO_QUERY_THROW ); @@ -1240,9 +1240,7 @@ void ViewShellBase::Implementation::ProcessRestoreEditingViewSlot (void) pHelper->RequestView( pHelper->GetViewURL(pFrameView->GetViewShellTypeOnLoad()), FrameworkHelper::msCenterPaneURL); - pHelper->RunOnConfigurationEvent( - ::rtl::OUString("ConfigurationUpdateEnd"), - CurrentPageSetter(mrBase)); + pHelper->RunOnConfigurationEvent("ConfigurationUpdateEnd", CurrentPageSetter(mrBase)); } } } diff --git a/sd/source/ui/view/drviews7.cxx b/sd/source/ui/view/drviews7.cxx index 574895e3f8f2..36c0aae71ec1 100644 --- a/sd/source/ui/view/drviews7.cxx +++ b/sd/source/ui/view/drviews7.cxx @@ -1503,8 +1503,7 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet ) if( xPropSet.is() ) { uno::Reference< beans::XPropertySetInfo > xPropInfo( xPropSet->getPropertySetInfo() ); - if( xPropInfo.is() && xPropInfo->hasPropertyByName( - rtl::OUString( "TargetURL"))) + if( xPropInfo.is() && xPropInfo->hasPropertyByName( "TargetURL") ) { bDisableEditHyperlink = sal_False; } diff --git a/sd/source/ui/view/drviewsa.cxx b/sd/source/ui/view/drviewsa.cxx index 3d63a090bccc..6dd99c11d7d2 100644 --- a/sd/source/ui/view/drviewsa.cxx +++ b/sd/source/ui/view/drviewsa.cxx @@ -83,8 +83,7 @@ using namespace ::com::sun::star; using namespace ::com::sun::star::uno; namespace { -static const ::rtl::OUString MASTER_VIEW_TOOL_BAR_NAME( - ::rtl::OUString("masterviewtoolbar")); +static const ::rtl::OUString MASTER_VIEW_TOOL_BAR_NAME("masterviewtoolbar"); } namespace sd { @@ -389,7 +388,7 @@ void DrawViewShell::Construct(DrawDocShell* pDocSh, PageKind eInitialPageKind) if( xMgr.is() ) { mxScannerManager = ::com::sun::star::uno::Reference< ::com::sun::star::scanner::XScannerManager2 >( - xMgr->createInstance( ::rtl::OUString("com.sun.star.scanner.ScannerManager" ) ), + xMgr->createInstance( "com.sun.star.scanner.ScannerManager" ), ::com::sun::star::uno::UNO_QUERY ); if( mxScannerManager.is() ) diff --git a/sd/source/ui/view/drviewsb.cxx b/sd/source/ui/view/drviewsb.cxx index a2741a4acf2f..30768af8131e 100644 --- a/sd/source/ui/view/drviewsb.cxx +++ b/sd/source/ui/view/drviewsb.cxx @@ -692,7 +692,7 @@ void DrawViewShell::FuTemp02(SfxRequest& rReq) { try { - com::sun::star::uno::Reference < ::com::sun::star::ui::dialogs::XExecutableDialog > xDialog(::comphelper::getProcessServiceFactory()->createInstance(rtl::OUString("com.sun.star.comp.ui.XSLTFilterDialog")), com::sun::star::uno::UNO_QUERY); + com::sun::star::uno::Reference < ::com::sun::star::ui::dialogs::XExecutableDialog > xDialog(::comphelper::getProcessServiceFactory()->createInstance("com.sun.star.comp.ui.XSLTFilterDialog"), com::sun::star::uno::UNO_QUERY); if( xDialog.is() ) { xDialog->execute(); diff --git a/sd/source/ui/view/drviewse.cxx b/sd/source/ui/view/drviewse.cxx index 749d3c7b01b1..6cb95c89f218 100644 --- a/sd/source/ui/view/drviewse.cxx +++ b/sd/source/ui/view/drviewse.cxx @@ -1593,16 +1593,16 @@ void DrawViewShell::InsertURLButton(const String& rURL, const String& rText, Reference< awt::XControlModel > xControlModel( pUnoCtrl->GetUnoControlModel(), UNO_QUERY_THROW ); Reference< beans::XPropertySet > xPropSet( xControlModel, UNO_QUERY_THROW ); - xPropSet->setPropertyValue( OUString( "Label" ), Any( OUString( rText ) ) ); - xPropSet->setPropertyValue( OUString( "TargetURL" ), Any( sTargetURL ) ); + xPropSet->setPropertyValue("Label" , Any( OUString( rText ) ) ); + xPropSet->setPropertyValue("TargetURL" , Any( sTargetURL ) ); if( rTarget.Len() ) - xPropSet->setPropertyValue( OUString( "TargetFrame" ), Any( OUString( rTarget ) ) ); + xPropSet->setPropertyValue("TargetFrame" , Any( OUString( rTarget ) ) ); - xPropSet->setPropertyValue( OUString( "ButtonType" ), Any( form::FormButtonType_URL ) ); + xPropSet->setPropertyValue( "ButtonType" , Any( form::FormButtonType_URL ) ); if ( ::avmedia::MediaWindow::isMediaURL( rURL ) ) { - xPropSet->setPropertyValue( OUString( "DispatchURLInternal" ), Any( sal_True ) ); + xPropSet->setPropertyValue( "DispatchURLInternal" , Any( sal_True ) ); } } else @@ -1628,15 +1628,15 @@ void DrawViewShell::InsertURLButton(const String& rURL, const String& rText, Reference< awt::XControlModel > xControlModel( pUnoCtrl->GetUnoControlModel(), uno::UNO_QUERY_THROW ); Reference< beans::XPropertySet > xPropSet( xControlModel, uno::UNO_QUERY_THROW ); - xPropSet->setPropertyValue( OUString( "Label" ), Any( OUString( rText ) ) ); - xPropSet->setPropertyValue( OUString( "TargetURL" ), Any( sTargetURL ) ); + xPropSet->setPropertyValue( "Label" , Any( OUString( rText ) ) ); + xPropSet->setPropertyValue( "TargetURL" , Any( sTargetURL ) ); if( rTarget.Len() ) - xPropSet->setPropertyValue( OUString( "TargetFrame" ), Any( OUString( rTarget ) ) ); + xPropSet->setPropertyValue( "TargetFrame" , Any( OUString( rTarget ) ) ); - xPropSet->setPropertyValue( OUString( "ButtonType" ), Any( form::FormButtonType_URL ) ); + xPropSet->setPropertyValue( "ButtonType" , Any( form::FormButtonType_URL ) ); if ( ::avmedia::MediaWindow::isMediaURL( rURL ) ) - xPropSet->setPropertyValue( OUString( "DispatchURLInternal" ), Any( sal_True ) ); + xPropSet->setPropertyValue( "DispatchURLInternal" , Any( sal_True ) ); Point aPos; |