summaryrefslogtreecommitdiff
path: root/canvas
diff options
context:
space:
mode:
authorKrisztian Pinter <pin.terminator@gmail.com>2013-02-19 19:49:47 +0100
committerMichael Stahl <mstahl@redhat.com>2013-02-20 23:04:14 +0000
commit73f866aa6161146d2a96e3e9b65ce18ca25ca2c5 (patch)
tree3cce96b52969f4cd76f4ea6439d42c28665582f5 /canvas
parentd05287a9f1bd1aa82d4485013248bb24e692c6b6 (diff)
RTL_CONSTASCII_USTRINGPARAM and ::rtl:: removals
All RTL_CONSTASCII_USTRINGPARAMs removed from canvas Change-Id: Ie62d080eb58a05f7bb18aa1cc2f518c951145460 Reviewed-on: https://gerrit.libreoffice.org/2283 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
Diffstat (limited to 'canvas')
-rw-r--r--canvas/source/directx/dx_9rm.cxx17
-rw-r--r--canvas/source/directx/dx_canvas.cxx23
-rw-r--r--canvas/source/directx/dx_canvasbitmap.cxx12
-rw-r--r--canvas/source/directx/dx_canvascustomsprite.cxx12
-rw-r--r--canvas/source/directx/dx_canvasfont.cxx12
-rw-r--r--canvas/source/directx/dx_config.cxx15
-rw-r--r--canvas/source/directx/dx_spritecanvas.cxx9
-rw-r--r--canvas/source/directx/dx_spritedevicehelper.cxx9
-rw-r--r--canvas/source/directx/dx_textlayout.cxx12
9 files changed, 48 insertions, 73 deletions
diff --git a/canvas/source/directx/dx_9rm.cxx b/canvas/source/directx/dx_9rm.cxx
index b30b0a4ed980..e62a29f79359 100644
--- a/canvas/source/directx/dx_9rm.cxx
+++ b/canvas/source/directx/dx_9rm.cxx
@@ -585,9 +585,7 @@ namespace dxcanvas
if(!(create(rWindow)))
{
- throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Could not create DirectX device!") ),NULL);
+ throw lang::NoSupportException( "Could not create DirectX device!" ,NULL);
}
// allocate a single texture surface which can be used later.
@@ -606,9 +604,7 @@ namespace dxcanvas
(aPageSize.getY() < MIN_TEXTURE_SIZE))
{
throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Could not create DirectX device - "
- "insufficient texture space!") ),NULL);
+ "Could not create DirectX device - insufficient texture space!", NULL );
}
}
maPageSize=aPageSize;
@@ -623,8 +619,7 @@ namespace dxcanvas
NULL)) )
{
throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Could not create DirectX device - out of memory!")),NULL);
+ "Could not create DirectX device - out of memory!", NULL );
}
mpVertexBuffer=COMReference<IDirect3DVertexBuffer9>(pVB);
@@ -905,8 +900,7 @@ namespace dxcanvas
NULL)) )
{
throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Could not create offscreen surface - out of mem!") ),NULL);
+ "Could not create offscreen surface - out of mem!", NULL );
}
return COMReference<IDirect3DSurface9>(pSurface);
@@ -960,8 +954,7 @@ namespace dxcanvas
NULL)) )
{
throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Could not create DirectX device - out of memory!")),NULL);
+ "Could not create DirectX device - out of memory!", NULL );
}
mpVertexBuffer=COMReference<IDirect3DVertexBuffer9>(pVB);
diff --git a/canvas/source/directx/dx_canvas.cxx b/canvas/source/directx/dx_canvas.cxx
index 6fa20bef0b11..602224bb732c 100644
--- a/canvas/source/directx/dx_canvas.cxx
+++ b/canvas/source/directx/dx_canvas.cxx
@@ -96,10 +96,7 @@ namespace dxcanvas
const SystemGraphicsData* pSysData=reinterpret_cast<const SystemGraphicsData*>(aSeq.getConstArray());
if( !pSysData || !pSysData->hDC )
- throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Passed SystemGraphicsData or HDC invalid!")),
- NULL);
+ throw lang::NoSupportException( "Passed SystemGraphicsData or HDC invalid!" ), NULL);
// setup helper
maDeviceHelper.init( pSysData->hDC,
@@ -123,9 +120,9 @@ namespace dxcanvas
CanvasBaseT::disposeThis();
}
- ::rtl::OUString SAL_CALL Canvas::getServiceName( ) throw (uno::RuntimeException)
+ OUString SAL_CALL Canvas::getServiceName( ) throw (uno::RuntimeException)
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CANVAS_SERVICE_NAME ) );
+ return OUString( CANVAS_SERVICE_NAME );
}
BitmapCanvas::BitmapCanvas( const uno::Sequence< uno::Any >& aArguments,
@@ -156,10 +153,7 @@ namespace dxcanvas
const SystemGraphicsData* pSysData=reinterpret_cast<const SystemGraphicsData*>(aSeq.getConstArray());
if( !pSysData || !pSysData->hDC )
- throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Passed SystemGraphicsData or HDC invalid!")),
- NULL);
+ throw lang::NoSupportException( "Passed SystemGraphicsData or HDC invalid!", NULL);
// setup helper
maDeviceHelper.init( pSysData->hDC,
@@ -173,10 +167,7 @@ namespace dxcanvas
hBmp=(HBITMAP)GetCurrentObject(pSysData->hDC, OBJ_BITMAP);
if( !hBmp || GetObjectType(pSysData->hDC) != OBJ_MEMDC )
{
- throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Passed HDC is no mem DC/has no bitmap selected!")),
- NULL);
+ throw lang::NoSupportException( "Passed HDC is no mem DC/has no bitmap selected!", NULL);
}
mpTarget.reset( new DXBitmap(
@@ -201,9 +192,9 @@ namespace dxcanvas
BitmapCanvasBaseT::disposeThis();
}
- ::rtl::OUString SAL_CALL BitmapCanvas::getServiceName( ) throw (uno::RuntimeException)
+ OUString SAL_CALL BitmapCanvas::getServiceName( ) throw (uno::RuntimeException)
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( BITMAPCANVAS_SERVICE_NAME ) );
+ return OUString( BITMAPCANVAS_SERVICE_NAME );
}
IBitmapSharedPtr BitmapCanvas::getBitmap() const
diff --git a/canvas/source/directx/dx_canvasbitmap.cxx b/canvas/source/directx/dx_canvasbitmap.cxx
index b90308193af0..64eb81d73e03 100644
--- a/canvas/source/directx/dx_canvasbitmap.cxx
+++ b/canvas/source/directx/dx_canvasbitmap.cxx
@@ -246,20 +246,20 @@ namespace dxcanvas
#define IMPLEMENTATION_NAME "DXCanvas.CanvasBitmap"
#define SERVICE_NAME "com.sun.star.rendering.CanvasBitmap"
- ::rtl::OUString SAL_CALL CanvasBitmap::getImplementationName( ) throw (uno::RuntimeException)
+ OUString SAL_CALL CanvasBitmap::getImplementationName( ) throw (uno::RuntimeException)
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( IMPLEMENTATION_NAME ) );
+ return OUString( IMPLEMENTATION_NAME );
}
- sal_Bool SAL_CALL CanvasBitmap::supportsService( const ::rtl::OUString& ServiceName ) throw (uno::RuntimeException)
+ sal_Bool SAL_CALL CanvasBitmap::supportsService( const OUString& ServiceName ) throw (uno::RuntimeException)
{
return ServiceName == SERVICE_NAME;
}
- uno::Sequence< ::rtl::OUString > SAL_CALL CanvasBitmap::getSupportedServiceNames( ) throw (uno::RuntimeException)
+ uno::Sequence< OUString > SAL_CALL CanvasBitmap::getSupportedServiceNames( ) throw (uno::RuntimeException)
{
- uno::Sequence< ::rtl::OUString > aRet(1);
- aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) );
+ uno::Sequence< OUString > aRet(1);
+ aRet[0] = SERVICE_NAME;
return aRet;
}
diff --git a/canvas/source/directx/dx_canvascustomsprite.cxx b/canvas/source/directx/dx_canvascustomsprite.cxx
index 62b6bf83201b..f2f50fe93e40 100644
--- a/canvas/source/directx/dx_canvascustomsprite.cxx
+++ b/canvas/source/directx/dx_canvascustomsprite.cxx
@@ -86,20 +86,20 @@ namespace dxcanvas
#define IMPLEMENTATION_NAME "DXCanvas.CanvasCustomSprite"
#define SERVICE_NAME "com.sun.star.rendering.CanvasCustomSprite"
- ::rtl::OUString SAL_CALL CanvasCustomSprite::getImplementationName() throw( uno::RuntimeException )
+ OUString SAL_CALL CanvasCustomSprite::getImplementationName() throw( uno::RuntimeException )
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( IMPLEMENTATION_NAME ) );
+ return OUString( IMPLEMENTATION_NAME );
}
- sal_Bool SAL_CALL CanvasCustomSprite::supportsService( const ::rtl::OUString& ServiceName ) throw( uno::RuntimeException )
+ sal_Bool SAL_CALL CanvasCustomSprite::supportsService( const OUString& ServiceName ) throw( uno::RuntimeException )
{
return ServiceName == SERVICE_NAME;
}
- uno::Sequence< ::rtl::OUString > SAL_CALL CanvasCustomSprite::getSupportedServiceNames() throw( uno::RuntimeException )
+ uno::Sequence< OUString > SAL_CALL CanvasCustomSprite::getSupportedServiceNames() throw( uno::RuntimeException )
{
- uno::Sequence< ::rtl::OUString > aRet(1);
- aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) );
+ uno::Sequence< OUString > aRet(1);
+ aRet[0] = SERVICE_NAME;
return aRet;
}
diff --git a/canvas/source/directx/dx_canvasfont.cxx b/canvas/source/directx/dx_canvasfont.cxx
index 27c44e895b5f..57690d3325e9 100644
--- a/canvas/source/directx/dx_canvasfont.cxx
+++ b/canvas/source/directx/dx_canvasfont.cxx
@@ -122,20 +122,20 @@ namespace dxcanvas
#define SERVICE_NAME "com.sun.star.rendering.CanvasFont"
#define IMPLEMENTATION_NAME "DXCanvas::CanvasFont"
- ::rtl::OUString SAL_CALL CanvasFont::getImplementationName() throw( uno::RuntimeException )
+ OUString SAL_CALL CanvasFont::getImplementationName() throw( uno::RuntimeException )
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( IMPLEMENTATION_NAME ) );
+ return OUString( IMPLEMENTATION_NAME );
}
- sal_Bool SAL_CALL CanvasFont::supportsService( const ::rtl::OUString& ServiceName ) throw( uno::RuntimeException )
+ sal_Bool SAL_CALL CanvasFont::supportsService( const OUString& ServiceName ) throw( uno::RuntimeException )
{
return ServiceName == SERVICE_NAME;
}
- uno::Sequence< ::rtl::OUString > SAL_CALL CanvasFont::getSupportedServiceNames() throw( uno::RuntimeException )
+ uno::Sequence< OUString > SAL_CALL CanvasFont::getSupportedServiceNames() throw( uno::RuntimeException )
{
- uno::Sequence< ::rtl::OUString > aRet(1);
- aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) );
+ uno::Sequence< OUString > aRet(1);
+ aRet[0] = SERVICE_NAME;
return aRet;
}
diff --git a/canvas/source/directx/dx_config.cxx b/canvas/source/directx/dx_config.cxx
index ea50d6b6aff5..117d625f0ff0 100644
--- a/canvas/source/directx/dx_config.cxx
+++ b/canvas/source/directx/dx_config.cxx
@@ -32,8 +32,7 @@ namespace dxcanvas
{
DXCanvasItem::DXCanvasItem() :
ConfigItem(
- ::rtl::OUString(
- RTL_CONSTASCII_USTRINGPARAM( "Office.Canvas/DXCanvas" )),
+ "Office.Canvas/DXCanvas",
CONFIG_MODE_IMMEDIATE_UPDATE ),
maValues(),
maMaxTextureSize(),
@@ -42,8 +41,8 @@ namespace dxcanvas
{
try
{
- uno::Sequence< ::rtl::OUString > aName(1);
- aName[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "DeviceBlacklist" ));
+ uno::Sequence< OUString > aName(1);
+ aName[0] = "DeviceBlacklist";
uno::Sequence< uno::Any > aProps( GetProperties( aName ));
uno::Sequence< sal_Int32 > aValues;
@@ -68,12 +67,12 @@ namespace dxcanvas
}
}
- aName[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "BlacklistCurrentDevice" ));
+ aName[0] = "BlacklistCurrentDevice";
aProps = GetProperties( aName );
if( aProps.getLength() > 0 )
aProps[0] >>= mbBlacklistCurrentDevice;
- aName[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "MaxTextureSize" ));
+ aName[0] = "MaxTextureSize";
aProps = GetProperties( aName );
if( aProps.getLength() > 0 )
maMaxTextureSize.reset( aProps[0].get<sal_Int32>() );
@@ -95,8 +94,8 @@ namespace dxcanvas
try
{
- uno::Sequence< ::rtl::OUString > aName(1);
- aName[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "DeviceBlacklist" ));
+ uno::Sequence< OUString > aName(1);
+ aName[0] = "DeviceBlacklist";
uno::Sequence< sal_Int32 > aValues( sizeof(DeviceInfo)/sizeof(sal_Int32)*maValues.size() );
diff --git a/canvas/source/directx/dx_spritecanvas.cxx b/canvas/source/directx/dx_spritecanvas.cxx
index b3597972caa2..d2dbc34779c7 100644
--- a/canvas/source/directx/dx_spritecanvas.cxx
+++ b/canvas/source/directx/dx_spritecanvas.cxx
@@ -90,10 +90,7 @@ namespace dxcanvas
maArguments[4] >>= xParentWindow;
Window* pParentWindow = VCLUnoHelper::GetWindow(xParentWindow);
if( !pParentWindow )
- throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Parent window not VCL window, or canvas out-of-process!")),
- NULL);
+ throw lang::NoSupportException( "Parent window not VCL window, or canvas out-of-process!", NULL);
awt::Rectangle aRect;
maArguments[2] >>= aRect;
@@ -158,9 +155,9 @@ namespace dxcanvas
mbSurfaceDirty );
}
- ::rtl::OUString SAL_CALL SpriteCanvas::getServiceName( ) throw (uno::RuntimeException)
+ OUString SAL_CALL SpriteCanvas::getServiceName( ) throw (uno::RuntimeException)
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( SPRITECANVAS_SERVICE_NAME ) );
+ return OUString( SPRITECANVAS_SERVICE_NAME );
}
const IDXRenderModuleSharedPtr& SpriteCanvas::getRenderModule() const
diff --git a/canvas/source/directx/dx_spritedevicehelper.cxx b/canvas/source/directx/dx_spritedevicehelper.cxx
index 366e0a5b06e7..f1fda287d455 100644
--- a/canvas/source/directx/dx_spritedevicehelper.cxx
+++ b/canvas/source/directx/dx_spritedevicehelper.cxx
@@ -73,10 +73,7 @@ namespace dxcanvas
const SystemEnvData *pData = rWindow.GetSystemData();
const HWND hWnd = reinterpret_cast<HWND>(pData->hWnd);
if( !IsWindow( hWnd ) )
- throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Passed window has invalid system window, or canvas out-of-process!")),
- NULL);
+ throw lang::NoSupportException( "Passed window has invalid system window, or canvas out-of-process!", NULL);
mpSpriteCanvas = &rSpriteCanvas;
@@ -87,9 +84,7 @@ namespace dxcanvas
}
catch (...) {
- throw lang::NoSupportException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
- "Could not create DirectX device!") ),
+ throw lang::NoSupportException( "Could not create DirectX device!",
static_cast< ::cppu::OWeakObject* >(&rSpriteCanvas) );
}
diff --git a/canvas/source/directx/dx_textlayout.cxx b/canvas/source/directx/dx_textlayout.cxx
index 9a4129f8bf77..3afdc42fd459 100644
--- a/canvas/source/directx/dx_textlayout.cxx
+++ b/canvas/source/directx/dx_textlayout.cxx
@@ -250,20 +250,20 @@ namespace dxcanvas
#define SERVICE_NAME "com.sun.star.rendering.TextLayout"
#define IMPLEMENTATION_NAME "DXCanvas::TextLayout"
- ::rtl::OUString SAL_CALL TextLayout::getImplementationName() throw( uno::RuntimeException )
+ OUString SAL_CALL TextLayout::getImplementationName() throw( uno::RuntimeException )
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( IMPLEMENTATION_NAME ) );
+ return OUString( IMPLEMENTATION_NAME );
}
- sal_Bool SAL_CALL TextLayout::supportsService( const ::rtl::OUString& ServiceName ) throw( uno::RuntimeException )
+ sal_Bool SAL_CALL TextLayout::supportsService( const OUString& ServiceName ) throw( uno::RuntimeException )
{
return ServiceName == SERVICE_NAME;
}
- uno::Sequence< ::rtl::OUString > SAL_CALL TextLayout::getSupportedServiceNames() throw( uno::RuntimeException )
+ uno::Sequence< OUString > SAL_CALL TextLayout::getSupportedServiceNames() throw( uno::RuntimeException )
{
- uno::Sequence< ::rtl::OUString > aRet(1);
- aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) );
+ uno::Sequence< OUString > aRet(1);
+ aRet[0] = SERVICE_NAME;
return aRet;
}