Kaydet (Commit) 50a7098b authored tarafından Ricardo Montania's avatar Ricardo Montania Kaydeden (comit) Olivier Hallot

More ::rtl::OUString -> OUString in canvas

Change-Id: If99dfc98ace1bf62cd5ab05c596f4f6ffc5fbd2f
Reviewed-on: https://gerrit.libreoffice.org/1175Tested-by: 's avatarOlivier Hallot <olivier.hallot@alta.org.br>
Reviewed-by: 's avatarOlivier Hallot <olivier.hallot@alta.org.br>
üst 47b78e10
...@@ -396,8 +396,7 @@ namespace canvas ...@@ -396,8 +396,7 @@ namespace canvas
{ {
#if OSL_DEBUG_LEVEL > 0 #if OSL_DEBUG_LEVEL > 0
throw ::com::sun::star::lang::IllegalArgumentException( throw ::com::sun::star::lang::IllegalArgumentException(
::rtl::OUString::createFromAscii(pStr) + OUString::createFromAscii(pStr) + ": reference is NULL",
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ": reference is NULL" )),
xIf, xIf,
nArgPos ); nArgPos );
#else #else
......
...@@ -90,26 +90,18 @@ namespace cairocanvas ...@@ -90,26 +90,18 @@ namespace cairocanvas
const SystemGraphicsData* pSysData=reinterpret_cast<const SystemGraphicsData*>(aSeq.getConstArray()); const SystemGraphicsData* pSysData=reinterpret_cast<const SystemGraphicsData*>(aSeq.getConstArray());
if( !pSysData || !pSysData->nSize ) if( !pSysData || !pSysData->nSize )
throw lang::NoSupportException( throw lang::NoSupportException( "Passed SystemGraphicsData invalid!", NULL);
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"Passed SystemGraphicsData invalid!")),
NULL);
bool bHasXRender = IsCairoWorking(pOutDev); bool bHasXRender = IsCairoWorking(pOutDev);
ENSURE_ARG_OR_THROW( bHasXRender == true, ENSURE_ARG_OR_THROW( bHasXRender == true, "SpriteCanvas::SpriteCanvas: No RENDER extension" );
"SpriteCanvas::SpriteCanvas: No RENDER extension" );
// setup helper // setup helper
maDeviceHelper.init( *this, maDeviceHelper.init( *this, *pOutDev );
*pOutDev );
maCanvasHelper.init( basegfx::B2ISize(aBounds.Width, aBounds.Height), maCanvasHelper.init( basegfx::B2ISize(aBounds.Width, aBounds.Height), *this, this );
*this, this );
// forward surface to render on to canvashelper // forward surface to render on to canvashelper
maCanvasHelper.setSurface( maCanvasHelper.setSurface( maDeviceHelper.getSurface(), false );
maDeviceHelper.getSurface(),
false );
maArguments.realloc(0); maArguments.realloc(0);
} }
...@@ -129,9 +121,9 @@ namespace cairocanvas ...@@ -129,9 +121,9 @@ namespace cairocanvas
CanvasBaseT::disposeThis(); 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 );
} }
bool Canvas::repaint( const SurfaceSharedPtr& pSurface, bool Canvas::repaint( const SurfaceSharedPtr& pSurface,
......
...@@ -254,20 +254,20 @@ namespace cairocanvas ...@@ -254,20 +254,20 @@ namespace cairocanvas
#define IMPLEMENTATION_NAME "CairoCanvas.CanvasBitmap" #define IMPLEMENTATION_NAME "CairoCanvas.CanvasBitmap"
#define SERVICE_NAME "com.sun.star.rendering.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; 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); uno::Sequence< OUString > aRet(1);
aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) ); aRet[0] = SERVICE_NAME;
return aRet; return aRet;
} }
......
...@@ -88,9 +88,9 @@ namespace cairocanvas ...@@ -88,9 +88,9 @@ namespace cairocanvas
DECLARE_UNO3_XCOMPONENT_AGG_DEFAULTS( CanvasBitmap, CanvasBitmapBase_Base, ::cppu::WeakComponentImplHelperBase ); DECLARE_UNO3_XCOMPONENT_AGG_DEFAULTS( CanvasBitmap, CanvasBitmapBase_Base, ::cppu::WeakComponentImplHelperBase );
// XServiceInfo // XServiceInfo
virtual ::rtl::OUString SAL_CALL getImplementationName( ) throw (::com::sun::star::uno::RuntimeException); virtual OUString SAL_CALL getImplementationName( ) throw (::com::sun::star::uno::RuntimeException);
virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException); virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames( ) throw (::com::sun::star::uno::RuntimeException); virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames( ) throw (::com::sun::star::uno::RuntimeException);
// SurfaceProvider // SurfaceProvider
virtual SurfaceSharedPtr getSurface(); virtual SurfaceSharedPtr getSurface();
......
...@@ -144,20 +144,20 @@ namespace cairocanvas ...@@ -144,20 +144,20 @@ namespace cairocanvas
#define IMPLEMENTATION_NAME "CairoCanvas.CanvasCustomSprite" #define IMPLEMENTATION_NAME "CairoCanvas.CanvasCustomSprite"
#define SERVICE_NAME "com.sun.star.rendering.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; 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); uno::Sequence< OUString > aRet(1);
aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) ); aRet[0] = SERVICE_NAME;
return aRet; return aRet;
} }
......
...@@ -112,9 +112,9 @@ namespace cairocanvas ...@@ -112,9 +112,9 @@ namespace cairocanvas
DECLARE_UNO3_XCOMPONENT_AGG_DEFAULTS( CanvasCustomSprite, CanvasCustomSpriteBase_Base, ::cppu::WeakComponentImplHelperBase ); DECLARE_UNO3_XCOMPONENT_AGG_DEFAULTS( CanvasCustomSprite, CanvasCustomSpriteBase_Base, ::cppu::WeakComponentImplHelperBase );
// XServiceInfo // XServiceInfo
virtual ::rtl::OUString SAL_CALL getImplementationName() throw( ::com::sun::star::uno::RuntimeException ); virtual OUString SAL_CALL getImplementationName() throw( ::com::sun::star::uno::RuntimeException );
virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw( ::com::sun::star::uno::RuntimeException ); virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) throw( ::com::sun::star::uno::RuntimeException );
virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() throw( ::com::sun::star::uno::RuntimeException ); virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw( ::com::sun::star::uno::RuntimeException );
// Sprite // Sprite
virtual void redraw( const ::cairo::CairoSharedPtr& pCairo, virtual void redraw( const ::cairo::CairoSharedPtr& pCairo,
......
...@@ -141,20 +141,20 @@ namespace cairocanvas ...@@ -141,20 +141,20 @@ namespace cairocanvas
#define IMPLEMENTATION_NAME "CairoCanvas::CanvasFont" #define IMPLEMENTATION_NAME "CairoCanvas::CanvasFont"
#define SERVICE_NAME "com.sun.star.rendering.CanvasFont" #define SERVICE_NAME "com.sun.star.rendering.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; 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); uno::Sequence< OUString > aRet(1);
aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) ); aRet[0] = SERVICE_NAME;
return aRet; return aRet;
} }
......
...@@ -71,9 +71,9 @@ namespace cairocanvas ...@@ -71,9 +71,9 @@ namespace cairocanvas
virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > SAL_CALL getExtraFontProperties( ) throw (::com::sun::star::uno::RuntimeException); virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > SAL_CALL getExtraFontProperties( ) throw (::com::sun::star::uno::RuntimeException);
// XServiceInfo // XServiceInfo
virtual ::rtl::OUString SAL_CALL getImplementationName() throw( ::com::sun::star::uno::RuntimeException ); virtual OUString SAL_CALL getImplementationName() throw( ::com::sun::star::uno::RuntimeException );
virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw( ::com::sun::star::uno::RuntimeException ); virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) throw( ::com::sun::star::uno::RuntimeException );
virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() throw( ::com::sun::star::uno::RuntimeException ); virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw( ::com::sun::star::uno::RuntimeException );
::Font getVCLFont() const; ::Font getVCLFont() const;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment