diff options
author | Caolán McNamara <caolanm@redhat.com> | 2015-03-18 13:38:11 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-03-18 17:24:03 +0000 |
commit | f59345721b1731c0fd5ed052f2dee99042bd7f4c (patch) | |
tree | 71feccd2b8828d9842086cdb3cb23837af5a12f2 /canvas/source | |
parent | 8a5069cbaacf8a78ee66d6d8f2a46daefe1bec56 (diff) |
move the cairo resize hack into vcl
Change-Id: Ifd1817a28f4fb7ddcc85447fd3388fd0efd86476
Diffstat (limited to 'canvas/source')
-rw-r--r-- | canvas/source/cairo/cairo_devicehelper.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/canvas/source/cairo/cairo_devicehelper.cxx b/canvas/source/cairo/cairo_devicehelper.cxx index fab8b1b0e754..05266e424457 100644 --- a/canvas/source/cairo/cairo_devicehelper.cxx +++ b/canvas/source/cairo/cairo_devicehelper.cxx @@ -17,8 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ -#include <config_features.h> - #include <canvas/debug.hxx> #include <canvas/verbosetrace.hxx> #include <canvas/canvastools.hxx> @@ -94,18 +92,20 @@ namespace cairocanvas OutputDevice* pOutDev=getOutputDevice(); -#if HAVE_FEATURE_X11 - // X11 only - if( mpSurface ) + if (mpSurface && pOutDev->CanResizeCairoSurface()) + { + // X11 only mpSurface->Resize( rSize.getX() + pOutDev->GetOutOffXPixel(), rSize.getY() + pOutDev->GetOutOffYPixel() ); + } else -#endif + { mpSurface = cairo::createSurface( *pOutDev, pOutDev->GetOutOffXPixel(), pOutDev->GetOutOffYPixel(), rSize.getX(), rSize.getY() ); + } } geometry::RealSize2D DeviceHelper::getPhysicalResolution() |