diff options
author | Noel Grandin <noel@peralex.com> | 2013-11-12 09:33:27 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2013-11-13 09:08:08 +0200 |
commit | 9c5a91efdb41cd340936846169da130d855a335a (patch) | |
tree | b7a10f7682a9e85c3ff8bdf56549166439b3a429 /sw | |
parent | 74816814a2c03ab5305e47c6d1f6e04f6918d946 (diff) |
expand out the A2S macro
Which is not doing anything useful anymore.
Change-Id: I83422e811d52a77b65655924c07b55dd7229449c
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/ui/sidebar/PagePropertyPanel.cxx | 18 | ||||
-rw-r--r-- | sw/source/ui/sidebar/SwPanelFactory.cxx | 11 |
2 files changed, 13 insertions, 16 deletions
diff --git a/sw/source/ui/sidebar/PagePropertyPanel.cxx b/sw/source/ui/sidebar/PagePropertyPanel.cxx index 90a9b3a5dab1..684da1a65642 100644 --- a/sw/source/ui/sidebar/PagePropertyPanel.cxx +++ b/sw/source/ui/sidebar/PagePropertyPanel.cxx @@ -55,8 +55,6 @@ const char UNO_MARGIN[] = ".uno:Margin"; const char UNO_SIZE[] = ".uno:Size"; const char UNO_COLUMN[] = ".uno:Column"; -#define A2S(pString) (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(pString))) - namespace { const cssu::Reference< css::document::XUndoManager > getUndoManager( const cssu::Reference< css::frame::XFrame >& rxFrame ) { @@ -88,11 +86,11 @@ PagePropertyPanel* PagePropertyPanel::Create ( SfxBindings* pBindings) { if (pParent == NULL) - throw ::com::sun::star::lang::IllegalArgumentException(A2S("no parent Window given to PagePropertyPanel::Create"), NULL, 0); + throw ::com::sun::star::lang::IllegalArgumentException("no parent Window given to PagePropertyPanel::Create", NULL, 0); if ( ! rxFrame.is()) - throw ::com::sun::star::lang::IllegalArgumentException(A2S("no XFrame given to PagePropertyPanel::Create"), NULL, 1); + throw ::com::sun::star::lang::IllegalArgumentException("no XFrame given to PagePropertyPanel::Create", NULL, 1); if (pBindings == NULL) - throw ::com::sun::star::lang::IllegalArgumentException(A2S("no SfxBindings given to PagePropertyPanel::Create"), NULL, 2); + throw ::com::sun::star::lang::IllegalArgumentException("no SfxBindings given to PagePropertyPanel::Create", NULL, 2); return new PagePropertyPanel( pParent, @@ -172,16 +170,16 @@ PagePropertyPanel::PagePropertyPanel( , maOrientationPopup( this, ::boost::bind( &PagePropertyPanel::CreatePageOrientationControl, this, _1 ), - A2S("Page orientation") ) + OUString("Page orientation") ) , maMarginPopup( this, ::boost::bind( &PagePropertyPanel::CreatePageMarginControl, this, _1 ), - A2S("Page margins") ) + OUString("Page margins") ) , maSizePopup( this, ::boost::bind( &PagePropertyPanel::CreatePageSizeControl, this, _1 ), - A2S("Page size") ) + OUString("Page size") ) , maColumnPopup( this, ::boost::bind( &PagePropertyPanel::CreatePageColumnControl, this, _1 ), - A2S("Page columns") ) + OUString("Page columns") ) , mxUndoManager( getUndoManager( rxFrame ) ) @@ -757,7 +755,7 @@ void PagePropertyPanel::StartUndo() { if ( mxUndoManager.is() ) { - mxUndoManager->enterUndoContext( A2S("") ); + mxUndoManager->enterUndoContext( OUString("") ); } } diff --git a/sw/source/ui/sidebar/SwPanelFactory.cxx b/sw/source/ui/sidebar/SwPanelFactory.cxx index c82f11ee8765..46edc90b1cb5 100644 --- a/sw/source/ui/sidebar/SwPanelFactory.cxx +++ b/sw/source/ui/sidebar/SwPanelFactory.cxx @@ -40,14 +40,13 @@ using ::rtl::OUString; namespace sw { namespace sidebar { -#define A2S(s) ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(s)) #define IMPLEMENTATION_NAME "org.apache.openoffice.comp.sw.sidebar.SwPanelFactory" #define SERVICE_NAME "com.sun.star.ui.UIElementFactory" ::rtl::OUString SAL_CALL SwPanelFactory::getImplementationName (void) { - return A2S(IMPLEMENTATION_NAME); + return OUString(IMPLEMENTATION_NAME); } @@ -63,7 +62,7 @@ cssu::Reference<cssu::XInterface> SAL_CALL SwPanelFactory::createInstance( cssu::Sequence<OUString> SAL_CALL SwPanelFactory::getSupportedServiceNames (void) { cssu::Sequence<OUString> aServiceNames (1); - aServiceNames[0] = A2S(SERVICE_NAME); + aServiceNames[0] = SERVICE_NAME; return aServiceNames; } @@ -99,15 +98,15 @@ Reference<ui::XUIElement> SAL_CALL SwPanelFactory::createUIElement ( ::Window* pParentWindow = VCLUnoHelper::GetWindow(xParentWindow); if ( ! xParentWindow.is() || pParentWindow==NULL) throw RuntimeException( - A2S("PanelFactory::createUIElement called without ParentWindow"), + "PanelFactory::createUIElement called without ParentWindow", NULL); if ( ! xFrame.is()) throw RuntimeException( - A2S("PanelFactory::createUIElement called without Frame"), + "PanelFactory::createUIElement called without Frame", NULL); if (pBindings == NULL) throw RuntimeException( - A2S("PanelFactory::createUIElement called without SfxBindings"), + "PanelFactory::createUIElement called without SfxBindings", NULL); #define DoesResourceEndWith(s) rsResourceURL.endsWithAsciiL(s,strlen(s)) |