summaryrefslogtreecommitdiff
path: root/canvas
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2022-09-08 11:12:27 +0200
committerTomaž Vajngerl <quikee@gmail.com>2022-09-11 17:16:59 +0200
commitc747486335c089baf440b8f040d3ffdc14aa5049 (patch)
tree0d173f69ac82099cfb8bde3ac2831a682665391d /canvas
parent5f5f2f8107b6176654bfb9a30c21b7d5e0c62c6f (diff)
basegfx: replace typedef with a class B2DSize based on Size2D
Change-Id: Id8b3c2bcf0bf4be5aba2812b0edda479bc20c6a9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139683 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'canvas')
-rw-r--r--canvas/source/tools/canvascustomspritehelper.cxx10
-rw-r--r--canvas/source/vcl/spritecanvashelper.cxx2
2 files changed, 5 insertions, 7 deletions
diff --git a/canvas/source/tools/canvascustomspritehelper.cxx b/canvas/source/tools/canvascustomspritehelper.cxx
index 39c71b3a646d..975d62325d49 100644
--- a/canvas/source/tools/canvascustomspritehelper.cxx
+++ b/canvas/source/tools/canvascustomspritehelper.cxx
@@ -191,16 +191,14 @@ namespace canvas
if( xBitmap->hasAlpha() )
return;
- const geometry::IntegerSize2D& rInputSize(
- xBitmap->getSize() );
- const ::basegfx::B2DSize& rOurSize(
- rSprite->getSizePixel() );
+ const geometry::IntegerSize2D& rInputSize(xBitmap->getSize());
+ basegfx::B2DSize rOurSize(rSprite->getSizePixel().getX(), rSprite->getSizePixel().getY());
::basegfx::B2DHomMatrix aTransform;
if( tools::isInside(
::basegfx::B2DRectangle( 0.0,0.0,
- rOurSize.getX(),
- rOurSize.getY() ),
+ rOurSize.getWidth(),
+ rOurSize.getHeight() ),
::basegfx::B2DRectangle( 0.0,0.0,
rInputSize.Width,
rInputSize.Height ),
diff --git a/canvas/source/vcl/spritecanvashelper.cxx b/canvas/source/vcl/spritecanvashelper.cxx
index 94bb97a745e3..37f70a364267 100644
--- a/canvas/source/vcl/spritecanvashelper.cxx
+++ b/canvas/source/vcl/spritecanvashelper.cxx
@@ -60,7 +60,7 @@ namespace vclcanvas
double calcNumPixel( const ::canvas::Sprite::Reference& rSprite )
{
- const ::basegfx::B2DSize& rSize(
+ const ::basegfx::B2DVector& rSize(
::boost::polymorphic_downcast< Sprite* >(rSprite.get())->getSizePixel() );
return rSize.getX() * rSize.getY();