include/vcl/bitmap.hxx              |   15 ++--
 include/vcl/bitmapex.hxx            |    4 -
 solenv/clang-format/blacklist       |    2 
 vcl/Library_vcl.mk                  |    1 
 vcl/inc/impbmp.hxx                  |   78 -----------------------
 vcl/inc/pch/precompiled_vcl.hxx     |    1 
 vcl/inc/salbmp.hxx                  |    6 +
 vcl/osx/salinst.cxx                 |    9 +-
 vcl/source/bitmap/bitmap.cxx        |   78 +++++++++++++----------
 vcl/source/bitmap/bitmappaint.cxx   |   14 ++--
 vcl/source/gdi/bitmap3.cxx          |   24 +++----
 vcl/source/gdi/bitmap4.cxx          |    1 
 vcl/source/gdi/bmpacc.cxx           |   18 +++--
 vcl/source/gdi/impbmp.cxx           |  120 ------------------------------------
 vcl/source/outdev/bitmap.cxx        |   41 +++++-------
 vcl/source/outdev/mask.cxx          |    9 +-
 vcl/source/window/introwin.cxx      |    1 
 vcl/source/window/window2.cxx       |    1 
 vcl/unx/generic/window/salframe.cxx |    5 -
 vcl/unx/gtk/gtksalframe.cxx         |    1 
 vcl/unx/gtk3/gtk3gtkframe.cxx       |    1 
 vcl/win/window/salframe.cxx         |    3 
 vcl/win/window/salmenu.cxx          |    1 
 23 files changed, 120 insertions(+), 314 deletions(-)

New commits:
commit f462a76f2bbaaaaaa79bf935a51bdf8cead25dbb
Author: Noel Grandin <noel.gran...@collabora.co.uk>
Date:   Mon Apr 16 11:27:31 2018 +0200

    remove ImpBitmap
    
    it's not adding anything useful, just hold the underlying SalBitmap
    instead
    
    Change-Id: I54852707b2f8af99283b9c882a428a8a7a11c4cf
    Reviewed-on: https://gerrit.libreoffice.org/52955
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>

diff --git a/include/vcl/bitmap.hxx b/include/vcl/bitmap.hxx
index 5740fc38eb63..cc50a6dc9bcc 100644
--- a/include/vcl/bitmap.hxx
+++ b/include/vcl/bitmap.hxx
@@ -187,7 +187,6 @@ class   BitmapInfoAccess;
 class   BitmapReadAccess;
 class   BitmapWriteAccess;
 class   BitmapPalette;
-class   ImpBitmap;
 class   Color;
 class   GDIMetaFile;
 class   AlphaMask;
@@ -227,8 +226,8 @@ public:
     inline bool             operator!() const;
     bool                    operator==( const Bitmap& rBitmap ) const;
     bool                    operator!=( const Bitmap& rBitmap ) const { return 
!operator==(rBitmap); }
-    // only compares if we are using the same internal copy-on-write Impl class
-    bool                    ShallowEquals( const Bitmap& rBitmap ) const { 
return mxImpBmp == rBitmap.mxImpBmp; }
+    // only compares if we are using the same internal copy-on-write SalBitmap 
class
+    bool                    ShallowEquals( const Bitmap& rBitmap ) const { 
return mxSalBmp == rBitmap.mxSalBmp; }
 
     inline bool             IsEmpty() const;
     void                    SetEmpty();
@@ -671,8 +670,8 @@ public:
     SAL_DLLPRIVATE void     ReassignWithSize(const Bitmap& rBitmap);
 
     SAL_DLLPRIVATE void     ImplMakeUnique();
-    const std::shared_ptr<ImpBitmap>& ImplGetImpBitmap() const { return 
mxImpBmp; }
-    SAL_DLLPRIVATE void     ImplSetImpBitmap( const 
std::shared_ptr<ImpBitmap>& xImpBmp );
+    const std::shared_ptr<SalBitmap>& ImplGetSalBitmap() const { return 
mxSalBmp; }
+    SAL_DLLPRIVATE void     ImplSetSalBitmap( const 
std::shared_ptr<SalBitmap>& xImpBmp );
 
     SAL_DLLPRIVATE bool     ImplScaleFast( const double& rScaleX, const 
double& rScaleY );
     SAL_DLLPRIVATE bool     ImplScaleInterpolate( const double& rScaleX, const 
double& rScaleY );
@@ -736,7 +735,7 @@ private:
     SAL_DLLPRIVATE bool ImplConvertGhosted();
 
 private:
-    std::shared_ptr<ImpBitmap> mxImpBmp;
+    std::shared_ptr<SalBitmap> mxSalBmp;
     MapMode maPrefMapMode;
     Size maPrefSize;
 
@@ -744,12 +743,12 @@ private:
 
 inline bool Bitmap::operator!() const
 {
-    return( mxImpBmp == nullptr );
+    return( mxSalBmp == nullptr );
 }
 
 inline bool Bitmap::IsEmpty() const
 {
-    return( mxImpBmp == nullptr );
+    return( mxSalBmp == nullptr );
 }
 
 inline const MapMode& Bitmap::GetPrefMapMode() const
diff --git a/include/vcl/bitmapex.hxx b/include/vcl/bitmapex.hxx
index dedd064b17d3..41b1fb28a010 100644
--- a/include/vcl/bitmapex.hxx
+++ b/include/vcl/bitmapex.hxx
@@ -463,8 +463,8 @@ public:
     void                CombineMaskOr(Color maskColor, sal_uInt8 nTol);
 public:
 
-    SAL_DLLPRIVATE std::shared_ptr<ImpBitmap> const & ImplGetBitmapImpBitmap() 
const { return maBitmap.ImplGetImpBitmap(); }
-    SAL_DLLPRIVATE std::shared_ptr<ImpBitmap> const & ImplGetMaskImpBitmap() 
const { return maMask.ImplGetImpBitmap(); }
+    SAL_DLLPRIVATE std::shared_ptr<SalBitmap> const & ImplGetBitmapSalBitmap() 
const { return maBitmap.ImplGetSalBitmap(); }
+    SAL_DLLPRIVATE std::shared_ptr<SalBitmap> const & ImplGetMaskSalBitmap() 
const { return maMask.ImplGetSalBitmap(); }
 
 
 private:
diff --git a/solenv/clang-format/blacklist b/solenv/clang-format/blacklist
index 277911b2b46d..3ef8903afca2 100644
--- a/solenv/clang-format/blacklist
+++ b/solenv/clang-format/blacklist
@@ -17587,7 +17587,6 @@ vcl/inc/headless/svpvd.hxx
 vcl/inc/helpwin.hxx
 vcl/inc/image.h
 vcl/inc/impanmvw.hxx
-vcl/inc/impbmp.hxx
 vcl/inc/impdel.hxx
 vcl/inc/impfont.hxx
 vcl/inc/impfontcache.hxx
@@ -18169,7 +18168,6 @@ vcl/source/gdi/graph.cxx
 vcl/source/gdi/graphictools.cxx
 vcl/source/gdi/hatch.cxx
 vcl/source/gdi/impanmvw.cxx
-vcl/source/gdi/impbmp.cxx
 vcl/source/gdi/impgraph.cxx
 vcl/source/gdi/impvect.cxx
 vcl/source/gdi/impvect.hxx
diff --git a/vcl/Library_vcl.mk b/vcl/Library_vcl.mk
index 93d1faf1826e..128541e5d0fd 100644
--- a/vcl/Library_vcl.mk
+++ b/vcl/Library_vcl.mk
@@ -268,7 +268,6 @@ $(eval $(call gb_Library_add_exception_objects,vcl,\
     vcl/source/gdi/graphictools \
     vcl/source/gdi/hatch \
     vcl/source/gdi/impanmvw \
-    vcl/source/gdi/impbmp \
     vcl/source/gdi/impgraph \
     vcl/source/gdi/impvect \
     vcl/source/gdi/jobset \
diff --git a/vcl/inc/impbmp.hxx b/vcl/inc/impbmp.hxx
deleted file mode 100644
index 57fb240f23b1..000000000000
--- a/vcl/inc/impbmp.hxx
+++ /dev/null
@@ -1,78 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#ifndef INCLUDED_VCL_INC_IMPBMP_HXX
-#define INCLUDED_VCL_INC_IMPBMP_HXX
-
-#include <memory>
-#include <vcl/salbtype.hxx>
-
-extern const sal_uLong nVCLRLut[ 6 ];
-extern const sal_uLong nVCLGLut[ 6 ];
-extern const sal_uLong nVCLBLut[ 6 ];
-extern const sal_uLong nVCLDitherLut[ 256 ];
-extern const sal_uLong nVCLLut[ 256 ];
-
-struct BitmapBuffer;
-class SalBitmap;
-class BitmapPalette;
-class SalGraphics;
-class Bitmap;
-
-class ImpBitmap
-{
-private:
-    std::unique_ptr<SalBitmap>
-                        mpSalBitmap;
-
-public:
-                        ImpBitmap();
-                        /**
-                         * takes ownership
-                         */
-                        ImpBitmap(SalBitmap* pBitmap);
-                        ~ImpBitmap();
-
-    bool                ImplIsEqual(const ImpBitmap& rBmp) const;
-
-    SalBitmap*          ImplGetSalBitmap() const { return mpSalBitmap.get(); }
-
-    void                Create( const Size& rSize, sal_uInt16 nBitCount, const 
BitmapPalette& rPal );
-    bool                Create( const ImpBitmap& rImpBitmap );
-    bool                Create( const ImpBitmap& rImpBitmap, SalGraphics* 
pGraphics );
-    bool                Create( const ImpBitmap& rImpBitmap, sal_uInt16 
nNewBitCount );
-
-    Size                GetSize() const;
-    sal_uInt16          GetBitCount() const;
-
-    BitmapBuffer*       AcquireBuffer( BitmapAccessMode nMode );
-    void                ReleaseBuffer( BitmapBuffer* pBuffer, BitmapAccessMode 
nMode );
-
-    BitmapChecksum      GetChecksum() const;
-    void                InvalidateChecksum();
-
-    bool                ScalingSupported() const;
-    bool                Scale( const double& rScaleX, const double& rScaleY, 
BmpScaleFlag nScaleFlag );
-    bool                Replace( const Color& rSearchColor, const Color& 
rReplaceColor, sal_uInt8 nTol );
-    bool                ConvertToGreyscale();
-};
-
-#endif // INCLUDED_VCL_INC_IMPBMP_HXX
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/inc/pch/precompiled_vcl.hxx b/vcl/inc/pch/precompiled_vcl.hxx
index 3c350c16e197..d3ca3bf1e6f3 100644
--- a/vcl/inc/pch/precompiled_vcl.hxx
+++ b/vcl/inc/pch/precompiled_vcl.hxx
@@ -266,7 +266,6 @@
 #include <i18nlangtag/lang.h>
 #include <i18nlangtag/languagetag.hxx>
 #include <i18nlangtag/mslangid.hxx>
-#include <impbmp.hxx>
 #include <o3tl/cow_wrapper.hxx>
 #include <o3tl/make_unique.hxx>
 #include <o3tl/strong_int.hxx>
diff --git a/vcl/inc/salbmp.hxx b/vcl/inc/salbmp.hxx
index a9bddd078004..7a89e82e057f 100644
--- a/vcl/inc/salbmp.hxx
+++ b/vcl/inc/salbmp.hxx
@@ -33,6 +33,12 @@ class BitmapPalette;
 struct BitmapSystemData;
 enum class BmpScaleFlag;
 
+extern const sal_uLong nVCLRLut[ 6 ];
+extern const sal_uLong nVCLGLut[ 6 ];
+extern const sal_uLong nVCLBLut[ 6 ];
+extern const sal_uLong nVCLDitherLut[ 256 ];
+extern const sal_uLong nVCLLut[ 256 ];
+
 class VCL_PLUGIN_PUBLIC SalBitmap
 {
 public:
diff --git a/vcl/osx/salinst.cxx b/vcl/osx/salinst.cxx
index 62a724a8bfae..b7a45c9a4f11 100644
--- a/vcl/osx/salinst.cxx
+++ b/vcl/osx/salinst.cxx
@@ -55,7 +55,6 @@
 #include <osx/runinmain.hxx>
 
 #include <print.h>
-#include <impbmp.hxx>
 #include <salimestatus.hxx>
 
 #include <comphelper/processfactory.hxx>
@@ -998,11 +997,11 @@ CGImageRef CreateCGImage( const Image& rImage )
     BitmapEx aBmpEx( rImage.GetBitmapEx() );
     Bitmap aBmp( aBmpEx.GetBitmap() );
 
-    if( ! aBmp || ! aBmp.ImplGetImpBitmap() )
+    if( ! aBmp || ! aBmp.ImplGetSalBitmap() )
         return nullptr;
 
     // simple case, no transparency
-    QuartzSalBitmap* pSalBmp = 
static_cast<QuartzSalBitmap*>(aBmp.ImplGetImpBitmap()->ImplGetSalBitmap());
+    QuartzSalBitmap* pSalBmp = 
static_cast<QuartzSalBitmap*>(aBmp.ImplGetSalBitmap().get());
 
     if( ! pSalBmp )
         return nullptr;
@@ -1014,7 +1013,7 @@ CGImageRef CreateCGImage( const Image& rImage )
     {
         AlphaMask aAlphaMask( aBmpEx.GetAlpha() );
         Bitmap aMask( aAlphaMask.GetBitmap() );
-        QuartzSalBitmap* pMaskBmp = 
static_cast<QuartzSalBitmap*>(aMask.ImplGetImpBitmap()->ImplGetSalBitmap());
+        QuartzSalBitmap* pMaskBmp = 
static_cast<QuartzSalBitmap*>(aMask.ImplGetSalBitmap().get());
         if( pMaskBmp )
             xImage = pSalBmp->CreateWithMask( *pMaskBmp, 0, 0, 
pSalBmp->mnWidth, pSalBmp->mnHeight );
         else
@@ -1023,7 +1022,7 @@ CGImageRef CreateCGImage( const Image& rImage )
     else if( aBmpEx.GetTransparentType() == TransparentType::Bitmap )
     {
         Bitmap aMask( aBmpEx.GetMask() );
-        QuartzSalBitmap* pMaskBmp = 
static_cast<QuartzSalBitmap*>(aMask.ImplGetImpBitmap()->ImplGetSalBitmap());
+        QuartzSalBitmap* pMaskBmp = 
static_cast<QuartzSalBitmap*>(aMask.ImplGetSalBitmap().get());
         if( pMaskBmp )
             xImage = pSalBmp->CreateWithMask( *pMaskBmp, 0, 0, 
pSalBmp->mnWidth, pSalBmp->mnHeight );
         else
diff --git a/vcl/source/bitmap/bitmap.cxx b/vcl/source/bitmap/bitmap.cxx
index c1cf3027c2f0..b273bbfca983 100644
--- a/vcl/source/bitmap/bitmap.cxx
+++ b/vcl/source/bitmap/bitmap.cxx
@@ -22,7 +22,8 @@
 #include <vcl/bitmapaccess.hxx>
 #include <vcl/outdev.hxx>
 
-#include <impbmp.hxx>
+#include <svdata.hxx>
+#include <salinst.hxx>
 #include <salbmp.hxx>
 #include <bitmapwriteaccess.hxx>
 
@@ -34,16 +35,16 @@ Bitmap::Bitmap()
 }
 
 Bitmap::Bitmap(const Bitmap& rBitmap)
-    : mxImpBmp(rBitmap.mxImpBmp)
+    : mxSalBmp(rBitmap.mxSalBmp)
     , maPrefMapMode(rBitmap.maPrefMapMode)
     , maPrefSize(rBitmap.maPrefSize)
 {
 }
 
 Bitmap::Bitmap(SalBitmap* pSalBitmap)
-    : mxImpBmp(new ImpBitmap(pSalBitmap))
+    : mxSalBmp(pSalBitmap)
     , maPrefMapMode(MapMode(MapUnit::MapPixel))
-    , maPrefSize(mxImpBmp->GetSize())
+    , maPrefSize(mxSalBmp->GetSize())
 {
 }
 
@@ -103,8 +104,8 @@ Bitmap::Bitmap( const Size& rSizePixel, sal_uInt16 
nBitCount, const BitmapPalett
                 pRealPal = const_cast<BitmapPalette*>(pPal);
         }
 
-        mxImpBmp.reset(new ImpBitmap);
-        mxImpBmp->Create( rSizePixel, nBitCount, pRealPal ? *pRealPal : aPal );
+        mxSalBmp.reset(ImplGetSVData()->mpDefInst->CreateSalBitmap());
+        mxSalBmp->Create( rSizePixel, nBitCount, pRealPal ? *pRealPal : aPal );
     }
 }
 
@@ -213,7 +214,7 @@ Bitmap& Bitmap::operator=( const Bitmap& rBitmap )
 
     maPrefSize = rBitmap.maPrefSize;
     maPrefMapMode = rBitmap.maPrefMapMode;
-    mxImpBmp = rBitmap.mxImpBmp;
+    mxSalBmp = rBitmap.mxSalBmp;
 
     return *this;
 }
@@ -222,34 +223,43 @@ Bitmap& Bitmap::operator=( Bitmap&& rBitmap )
 {
     maPrefSize = std::move(rBitmap.maPrefSize);
     maPrefMapMode = std::move(rBitmap.maPrefMapMode);
-    mxImpBmp = std::move(rBitmap.mxImpBmp);
+    mxSalBmp = std::move(rBitmap.mxSalBmp);
 
     return *this;
 }
 
 bool Bitmap::operator==( const Bitmap& rBmp ) const
 {
-    return rBmp.mxImpBmp == mxImpBmp || // Includes both are nullptr
-           (rBmp.mxImpBmp && mxImpBmp && 
mxImpBmp->ImplIsEqual(*rBmp.mxImpBmp));
+    if (rBmp.mxSalBmp == mxSalBmp) // Includes both are nullptr
+        return true;
+    if (!rBmp.mxSalBmp || !mxSalBmp)
+        return false;
+    if (rBmp.mxSalBmp->GetSize() != mxSalBmp->GetSize() ||
+        rBmp.mxSalBmp->GetBitCount() != mxSalBmp->GetBitCount())
+        return false;
+    BitmapChecksum aChecksum1, aChecksum2;
+    rBmp.mxSalBmp->GetChecksum(aChecksum1);
+    mxSalBmp->GetChecksum(aChecksum2);
+    return aChecksum1 == aChecksum2;
 }
 
 void Bitmap::SetEmpty()
 {
     maPrefMapMode = MapMode();
     maPrefSize = Size();
-    mxImpBmp.reset();
+    mxSalBmp.reset();
 }
 
 Size Bitmap::GetSizePixel() const
 {
-    return( mxImpBmp ? mxImpBmp->GetSize() : Size() );
+    return( mxSalBmp ? mxSalBmp->GetSize() : Size() );
 }
 
 sal_uInt16 Bitmap::GetBitCount() const
 {
-    if (!mxImpBmp)
+    if (!mxSalBmp)
         return 0;
-    sal_uInt16 nBitCount = mxImpBmp->GetBitCount();
+    sal_uInt16 nBitCount = mxSalBmp->GetBitCount();
     return ( nBitCount <= 4 ) ? ( ( nBitCount <= 1 ) ? 1 : 4 ):
                                 ( ( nBitCount <= 8 ) ? 8 : 24);
 }
@@ -273,9 +283,9 @@ BitmapChecksum Bitmap::GetChecksum() const
 {
     BitmapChecksum nRet = 0;
 
-    if( mxImpBmp )
+    if( mxSalBmp )
     {
-        nRet = mxImpBmp->GetChecksum();
+        mxSalBmp->GetChecksum(nRet);
 
         if (!nRet)
         {
@@ -283,12 +293,12 @@ BitmapChecksum Bitmap::GetChecksum() const
             // the buffer in SalBitmap::updateChecksum;
             // so, we need to update the imp bitmap for this bitmap instance
             // as we do in BitmapInfoAccess::ImplCreate
-            std::shared_ptr<ImpBitmap> xNewImpBmp(new ImpBitmap);
-            if (xNewImpBmp->Create(*mxImpBmp, GetBitCount()))
+            std::shared_ptr<SalBitmap> 
xNewImpBmp(ImplGetSVData()->mpDefInst->CreateSalBitmap());
+            if (xNewImpBmp->Create(*mxSalBmp, GetBitCount()))
             {
                 Bitmap* pThis = const_cast<Bitmap*>(this);
-                pThis->mxImpBmp = xNewImpBmp;
-                nRet = mxImpBmp->GetChecksum();
+                pThis->mxSalBmp = xNewImpBmp;
+                mxSalBmp->GetChecksum(nRet);
             }
         }
     }
@@ -298,11 +308,11 @@ BitmapChecksum Bitmap::GetChecksum() const
 
 void Bitmap::ImplMakeUnique()
 {
-    if (mxImpBmp && mxImpBmp.use_count() > 1)
+    if (mxSalBmp && mxSalBmp.use_count() > 1)
     {
-        std::shared_ptr<ImpBitmap> xOldImpBmp = mxImpBmp;
-        mxImpBmp.reset(new ImpBitmap);
-        mxImpBmp->Create(*xOldImpBmp);
+        std::shared_ptr<SalBitmap> xOldImpBmp = mxSalBmp;
+        mxSalBmp.reset(ImplGetSVData()->mpDefInst->CreateSalBitmap());
+        mxSalBmp->Create(*xOldImpBmp);
     }
 }
 
@@ -330,9 +340,9 @@ void Bitmap::ReassignWithSize(const Bitmap& rBitmap)
 }
 
 
-void Bitmap::ImplSetImpBitmap(const std::shared_ptr<ImpBitmap>& xImpBmp)
+void Bitmap::ImplSetSalBitmap(const std::shared_ptr<SalBitmap>& xImpBmp)
 {
-    mxImpBmp = xImpBmp;
+    mxSalBmp = xImpBmp;
 }
 
 BitmapInfoAccess* Bitmap::AcquireInfoAccess()
@@ -437,7 +447,7 @@ bool Bitmap::CopyPixel( const tools::Rectangle& rRectDst,
 
     if( !aRectDst.IsEmpty() )
     {
-        if( pBmpSrc && ( pBmpSrc->mxImpBmp != mxImpBmp ) )
+        if( pBmpSrc && ( pBmpSrc->mxSalBmp != mxSalBmp ) )
         {
             Bitmap*         pSrc = const_cast<Bitmap*>(pBmpSrc);
             const Size      aCopySizePix( pSrc->GetSizePixel() );
@@ -644,7 +654,7 @@ bool Bitmap::CopyPixel_AlphaOptimized( const 
tools::Rectangle& rRectDst, const t
 
     if( !aRectDst.IsEmpty() )
     {
-        if( pBmpSrc && ( pBmpSrc->mxImpBmp != mxImpBmp ) )
+        if( pBmpSrc && ( pBmpSrc->mxSalBmp != mxSalBmp ) )
         {
             Bitmap*         pSrc = const_cast<Bitmap*>(pBmpSrc);
             const Size      aCopySizePix( pSrc->GetSizePixel() );
@@ -830,11 +840,11 @@ Bitmap Bitmap::CreateDisplayBitmap( OutputDevice* 
pDisplay )
 
     SalGraphics* pDispGraphics = pDisplay->GetGraphics();
 
-    if( mxImpBmp && pDispGraphics )
+    if( mxSalBmp && pDispGraphics )
     {
-        std::shared_ptr<ImpBitmap> xImpDispBmp(new ImpBitmap);
-        if (xImpDispBmp->Create(*mxImpBmp, pDispGraphics))
-            aDispBmp.ImplSetImpBitmap(xImpDispBmp);
+        std::shared_ptr<SalBitmap> 
xImpDispBmp(ImplGetSVData()->mpDefInst->CreateSalBitmap());
+        if (xImpDispBmp->Create(*mxSalBmp, pDispGraphics))
+            aDispBmp.ImplSetSalBitmap(xImpDispBmp);
     }
 
     return aDispBmp;
@@ -919,9 +929,9 @@ bool Bitmap::MakeMonochrome(sal_uInt8 cThreshold)
 bool Bitmap::GetSystemData( BitmapSystemData& rData ) const
 {
     bool bRet = false;
-    if (mxImpBmp)
+    if (mxSalBmp)
     {
-        SalBitmap* pSalBitmap = mxImpBmp->ImplGetSalBitmap();
+        SalBitmap* pSalBitmap = mxSalBmp.get();
         if( pSalBitmap )
             bRet = pSalBitmap->GetSystemData( rData );
     }
diff --git a/vcl/source/bitmap/bitmappaint.cxx 
b/vcl/source/bitmap/bitmappaint.cxx
index aa21c4d359b0..0bbd32559bfe 100644
--- a/vcl/source/bitmap/bitmappaint.cxx
+++ b/vcl/source/bitmap/bitmappaint.cxx
@@ -22,8 +22,10 @@
 #include <vcl/bitmapaccess.hxx>
 #include <vcl/alpha.hxx>
 
-#include <impbmp.hxx>
 #include <bitmapwriteaccess.hxx>
+#include <salbmp.hxx>
+#include <svdata.hxx>
+#include <salinst.hxx>
 
 #include <algorithm>
 #include <memory>
@@ -143,7 +145,7 @@ bool Bitmap::Invert()
             }
         }
 
-        mxImpBmp->InvalidateChecksum();
+        mxSalBmp->InvalidateChecksum();
         pAcc.reset();
         bRet = true;
     }
@@ -856,13 +858,13 @@ bool Bitmap::Replace(const AlphaMask& rAlpha, const 
Color& rMergeColor)
 
 bool Bitmap::Replace(const Color& rSearchColor, const Color& rReplaceColor, 
sal_uInt8 nTol)
 {
-    if (mxImpBmp)
+    if (mxSalBmp)
     {
         // implementation specific replace
-        std::shared_ptr<ImpBitmap> xImpBmp(new ImpBitmap);
-        if (xImpBmp->Create(*mxImpBmp) && xImpBmp->Replace(rSearchColor, 
rReplaceColor, nTol))
+        std::shared_ptr<SalBitmap> 
xImpBmp(ImplGetSVData()->mpDefInst->CreateSalBitmap());
+        if (xImpBmp->Create(*mxSalBmp) && xImpBmp->Replace(rSearchColor, 
rReplaceColor, nTol))
         {
-            ImplSetImpBitmap(xImpBmp);
+            ImplSetSalBitmap(xImpBmp);
             maPrefMapMode = MapMode(MapUnit::MapPixel);
             maPrefSize = xImpBmp->GetSize();
             return true;
diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx
index 7a0014b1b8c6..b553130c6538 100644
--- a/vcl/source/gdi/bitmap3.cxx
+++ b/vcl/source/gdi/bitmap3.cxx
@@ -28,7 +28,6 @@
 #include <vcl/opengl/OpenGLHelper.hxx>
 #endif
 
-#include <impbmp.hxx>
 #include <impoctree.hxx>
 #include <BitmapScaleSuperFilter.hxx>
 #include <BitmapScaleConvolutionFilter.hxx>
@@ -36,6 +35,9 @@
 #include <BitmapInterpolateScaleFilter.hxx>
 #include <bitmapwriteaccess.hxx>
 #include <octree.hxx>
+#include <svdata.hxx>
+#include <salinst.hxx>
+#include <salbmp.hxx>
 
 #include "impvect.hxx"
 
@@ -222,17 +224,17 @@ const long FloydIndexMap[6] =
 bool Bitmap::Convert( BmpConversion eConversion )
 {
     // try to convert in backend
-    if (mxImpBmp)
+    if (mxSalBmp)
     {
         // avoid large chunk of obsolete and hopefully rarely used conversions.
         if (eConversion == BmpConversion::N8BitGreys)
         {
-            std::shared_ptr<ImpBitmap> xImpBmp(new ImpBitmap);
+            std::shared_ptr<SalBitmap> 
xImpBmp(ImplGetSVData()->mpDefInst->CreateSalBitmap());
             // frequently used conversion for creating alpha masks
-            if (xImpBmp->Create(*mxImpBmp) && xImpBmp->ConvertToGreyscale())
+            if (xImpBmp->Create(*mxSalBmp) && xImpBmp->ConvertToGreyscale())
             {
-                ImplSetImpBitmap(xImpBmp);
-                SAL_INFO( "vcl.opengl", "Ref count: " << mxImpBmp.use_count() 
);
+                ImplSetSalBitmap(xImpBmp);
+                SAL_INFO( "vcl.opengl", "Ref count: " << mxSalBmp.use_count() 
);
                 return true;
             }
         }
@@ -732,14 +734,14 @@ bool Bitmap::Scale( const double& rScaleX, const double& 
rScaleY, BmpScaleFlag n
 
     const sal_uInt16 nStartCount(GetBitCount());
 
-    if (mxImpBmp && mxImpBmp->ScalingSupported())
+    if (mxSalBmp && mxSalBmp->ScalingSupported())
     {
         // implementation specific scaling
-        std::shared_ptr<ImpBitmap> xImpBmp(new ImpBitmap);
-        if (xImpBmp->Create(*mxImpBmp) && xImpBmp->Scale(rScaleX, rScaleY, 
nScaleFlag))
+        std::shared_ptr<SalBitmap> 
xImpBmp(ImplGetSVData()->mpDefInst->CreateSalBitmap());
+        if (xImpBmp->Create(*mxSalBmp) && xImpBmp->Scale(rScaleX, rScaleY, 
nScaleFlag))
         {
-            ImplSetImpBitmap(xImpBmp);
-            SAL_INFO( "vcl.opengl", "Ref count: " << mxImpBmp.use_count() );
+            ImplSetSalBitmap(xImpBmp);
+            SAL_INFO( "vcl.opengl", "Ref count: " << mxSalBmp.use_count() );
             maPrefMapMode = MapMode( MapUnit::MapPixel );
             maPrefSize = xImpBmp->GetSize();
             return true;
diff --git a/vcl/source/gdi/bitmap4.cxx b/vcl/source/gdi/bitmap4.cxx
index b63f5c480fe5..71fd484170ae 100644
--- a/vcl/source/gdi/bitmap4.cxx
+++ b/vcl/source/gdi/bitmap4.cxx
@@ -22,7 +22,6 @@
 #include <osl/diagnose.h>
 #include <vcl/bitmapaccess.hxx>
 #include <vcl/bitmap.hxx>
-#include <impbmp.hxx>
 #include <bitmapwriteaccess.hxx>
 
 #define S2(a,b)             { long t; if( ( t = b - a ) < 0 ) { a += t; b -= 
t; } }
diff --git a/vcl/source/gdi/bmpacc.cxx b/vcl/source/gdi/bmpacc.cxx
index a9e0618b103c..d507585891fb 100644
--- a/vcl/source/gdi/bmpacc.cxx
+++ b/vcl/source/gdi/bmpacc.cxx
@@ -21,8 +21,10 @@
 #include <vcl/bitmap.hxx>
 #include <vcl/bitmapaccess.hxx>
 
-#include <impbmp.hxx>
 #include <bitmapwriteaccess.hxx>
+#include <salbmp.hxx>
+#include <svdata.hxx>
+#include <salinst.hxx>
 
 #include <string.h>
 
@@ -30,17 +32,17 @@ BitmapInfoAccess::BitmapInfoAccess( Bitmap& rBitmap, 
BitmapAccessMode nMode ) :
             mpBuffer        ( nullptr ),
             mnAccessMode    ( nMode )
 {
-    std::shared_ptr<ImpBitmap> xImpBmp = rBitmap.ImplGetImpBitmap();
+    std::shared_ptr<SalBitmap> xImpBmp = rBitmap.ImplGetSalBitmap();
 
     SAL_WARN_IF( !xImpBmp, "vcl", "Forbidden Access to empty bitmap!" );
 
     if( xImpBmp )
     {
-        if( mnAccessMode == BitmapAccessMode::Write && 
!maBitmap.ImplGetImpBitmap() )
+        if( mnAccessMode == BitmapAccessMode::Write && 
!maBitmap.ImplGetSalBitmap() )
         {
             xImpBmp.reset();
             rBitmap.ImplMakeUnique();
-            xImpBmp = rBitmap.ImplGetImpBitmap();
+            xImpBmp = rBitmap.ImplGetSalBitmap();
         }
         else
         {
@@ -53,11 +55,11 @@ BitmapInfoAccess::BitmapInfoAccess( Bitmap& rBitmap, 
BitmapAccessMode nMode ) :
 
         if( !mpBuffer )
         {
-            std::shared_ptr<ImpBitmap> xNewImpBmp(new ImpBitmap);
+            std::shared_ptr<SalBitmap> 
xNewImpBmp(ImplGetSVData()->mpDefInst->CreateSalBitmap());
             if (xNewImpBmp->Create(*xImpBmp, rBitmap.GetBitCount()))
             {
                 xImpBmp = xNewImpBmp;
-                rBitmap.ImplSetImpBitmap( xImpBmp );
+                rBitmap.ImplSetSalBitmap( xImpBmp );
                 mpBuffer = xImpBmp->AcquireBuffer( mnAccessMode );
             }
         }
@@ -68,7 +70,7 @@ BitmapInfoAccess::BitmapInfoAccess( Bitmap& rBitmap, 
BitmapAccessMode nMode ) :
 
 BitmapInfoAccess::~BitmapInfoAccess()
 {
-    std::shared_ptr<ImpBitmap> xImpBmp = maBitmap.ImplGetImpBitmap();
+    std::shared_ptr<SalBitmap> xImpBmp = maBitmap.ImplGetSalBitmap();
 
     if (mpBuffer && xImpBmp)
     {
@@ -90,7 +92,7 @@ BitmapReadAccess::BitmapReadAccess( Bitmap& rBitmap, 
BitmapAccessMode nMode ) :
     if (!mpBuffer)
         return;
 
-    std::shared_ptr<ImpBitmap> xImpBmp = rBitmap.ImplGetImpBitmap();
+    std::shared_ptr<SalBitmap> xImpBmp = rBitmap.ImplGetSalBitmap();
     if (!xImpBmp)
         return;
 
diff --git a/vcl/source/gdi/impbmp.cxx b/vcl/source/gdi/impbmp.cxx
deleted file mode 100644
index 1bea17ce3173..000000000000
--- a/vcl/source/gdi/impbmp.cxx
+++ /dev/null
@@ -1,120 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include <vcl/bitmap.hxx>
-
-#include <svdata.hxx>
-#include <salinst.hxx>
-#include <salbmp.hxx>
-#include <impbmp.hxx>
-
-ImpBitmap::ImpBitmap()
-    : mpSalBitmap(ImplGetSVData()->mpDefInst->CreateSalBitmap())
-{
-}
-
-ImpBitmap::ImpBitmap(SalBitmap* pBitmap)
-    : mpSalBitmap(pBitmap)
-{
-}
-
-ImpBitmap::~ImpBitmap()
-{
-}
-
-bool ImpBitmap::ImplIsEqual(const ImpBitmap& rBmp) const
-{
-    return (rBmp.GetSize() == GetSize() &&
-        rBmp.GetBitCount() == GetBitCount() &&
-        rBmp.GetChecksum() == GetChecksum());
-}
-
-void ImpBitmap::Create(const Size& rSize, sal_uInt16 nBitCount, const 
BitmapPalette& rPal)
-{
-    mpSalBitmap->Create( rSize, nBitCount, rPal );
-}
-
-bool ImpBitmap::Create( const ImpBitmap& rImpBitmap )
-{
-    return mpSalBitmap->Create( *rImpBitmap.mpSalBitmap );
-}
-
-bool ImpBitmap::Create( const ImpBitmap& rImpBitmap, SalGraphics* pGraphics )
-{
-    return mpSalBitmap->Create( *rImpBitmap.mpSalBitmap, pGraphics );
-}
-
-bool ImpBitmap::Create( const ImpBitmap& rImpBitmap, sal_uInt16 nNewBitCount )
-{
-    return mpSalBitmap->Create( *rImpBitmap.mpSalBitmap, nNewBitCount );
-}
-
-Size ImpBitmap::GetSize() const
-{
-    return mpSalBitmap->GetSize();
-}
-
-sal_uInt16 ImpBitmap::GetBitCount() const
-{
-    return mpSalBitmap->GetBitCount();
-}
-
-BitmapBuffer* ImpBitmap::AcquireBuffer( BitmapAccessMode nMode )
-{
-    return mpSalBitmap->AcquireBuffer( nMode );
-}
-
-void ImpBitmap::ReleaseBuffer( BitmapBuffer* pBuffer, BitmapAccessMode nMode )
-{
-    mpSalBitmap->ReleaseBuffer( pBuffer, nMode );
-}
-
-BitmapChecksum ImpBitmap::GetChecksum() const
-{
-    BitmapChecksum aChecksum;
-    mpSalBitmap->GetChecksum(aChecksum);
-    return aChecksum;
-}
-
-void ImpBitmap::InvalidateChecksum()
-{
-    mpSalBitmap->InvalidateChecksum();
-}
-
-bool ImpBitmap::ScalingSupported() const
-{
-    return mpSalBitmap->ScalingSupported();
-}
-
-bool ImpBitmap::Scale( const double& rScaleX, const double& rScaleY, 
BmpScaleFlag nScaleFlag )
-{
-    return mpSalBitmap->Scale( rScaleX, rScaleY, nScaleFlag );
-}
-
-bool ImpBitmap::Replace( const Color& rSearchColor, const Color& 
rReplaceColor, sal_uInt8 nTol )
-{
-    return mpSalBitmap->Replace( rSearchColor, rReplaceColor, nTol );
-}
-
-bool ImpBitmap::ConvertToGreyscale()
-{
-    return mpSalBitmap->ConvertToGreyscale();
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/source/outdev/bitmap.cxx b/vcl/source/outdev/bitmap.cxx
index a9d2215f7791..75d6d9120ae7 100644
--- a/vcl/source/outdev/bitmap.cxx
+++ b/vcl/source/outdev/bitmap.cxx
@@ -35,7 +35,7 @@
 
 #include <bmpfast.hxx>
 #include <salgdi.hxx>
-#include <impbmp.hxx>
+#include <salbmp.hxx>
 #include <image.h>
 
 #include <basegfx/matrix/b2dhommatrixtools.hxx>
@@ -163,7 +163,7 @@ void OutputDevice::DrawBitmap( const Point& rDestPt, const 
Size& rDestSize,
                 if ( nAction == MetaActionType::BMPSCALE )
                     ScaleBitmap (aBmp, aPosAry);
 
-                mpGraphics->DrawBitmap( aPosAry, 
*aBmp.ImplGetImpBitmap()->ImplGetSalBitmap(), this );
+                mpGraphics->DrawBitmap( aPosAry, *aBmp.ImplGetSalBitmap(), 
this );
             }
         }
     }
@@ -468,8 +468,8 @@ Bitmap OutputDevice::GetBitmap( const Point& rSrcPt, const 
Size& rSize ) const
 
                 if( pSalBmp )
                 {
-                    std::shared_ptr<ImpBitmap> xImpBmp(new ImpBitmap(pSalBmp));
-                    aBmp.ImplSetImpBitmap(xImpBmp);
+                    std::shared_ptr<SalBitmap> xImpBmp(pSalBmp);
+                    aBmp.ImplSetSalBitmap(xImpBmp);
                 }
             }
         }
@@ -521,15 +521,14 @@ void OutputDevice::DrawDeviceBitmap( const Point& 
rDestPt, const Size& rDestSize
             if (nMirrFlags != BmpMirrorFlags::NONE)
                 rBitmapEx.Mirror(nMirrFlags);
 
-            const SalBitmap* pSalSrcBmp = 
rBitmapEx.ImplGetBitmapImpBitmap()->ImplGetSalBitmap();
-            std::shared_ptr<ImpBitmap> xMaskBmp = 
rBitmapEx.ImplGetMaskImpBitmap();
+            const SalBitmap* pSalSrcBmp = 
rBitmapEx.ImplGetBitmapSalBitmap().get();
+            std::shared_ptr<SalBitmap> xMaskBmp = 
rBitmapEx.ImplGetMaskSalBitmap();
 
             if (xMaskBmp)
             {
-                SalBitmap* pSalAlphaBmp = xMaskBmp->ImplGetSalBitmap();
-                bool bTryDirectPaint(pSalSrcBmp && pSalAlphaBmp);
+                bool bTryDirectPaint(pSalSrcBmp);
 
-                if (bTryDirectPaint && mpGraphics->DrawAlphaBitmap(aPosAry, 
*pSalSrcBmp, *pSalAlphaBmp, this))
+                if (bTryDirectPaint && mpGraphics->DrawAlphaBitmap(aPosAry, 
*pSalSrcBmp, *xMaskBmp, this))
                 {
                     // tried to paint as alpha directly. If tis worked, we are 
done (except
                     // alpha, see below)
@@ -592,9 +591,7 @@ void OutputDevice::DrawDeviceBitmap( const Point& rDestPt, 
const Size& rDestSize
                         }
                     }
 
-                    mpGraphics->DrawBitmap(aPosAry, *pSalSrcBmp,
-                                           *xMaskBmp->ImplGetSalBitmap(),
-                                           this);
+                    mpGraphics->DrawBitmap(aPosAry, *pSalSrcBmp, *xMaskBmp, 
this);
                 }
 
                 // #110958# Paint mask to alpha channel. Luckily, the
@@ -669,16 +666,16 @@ void OutputDevice::DrawDeviceAlphaBitmap( const Bitmap& 
rBmp, const AlphaMask& r
                 aRelPt.X(), aRelPt.Y(),
                 aOutSz.Width(), aOutSz.Height());
 
-            SalBitmap* pSalSrcBmp = 
rBmp.ImplGetImpBitmap()->ImplGetSalBitmap();
-            SalBitmap* pSalAlphaBmp = 
rAlpha.ImplGetImpBitmap()->ImplGetSalBitmap();
+            SalBitmap* pSalSrcBmp = rBmp.ImplGetSalBitmap().get();
+            SalBitmap* pSalAlphaBmp = rAlpha.ImplGetSalBitmap().get();
 
             // try to blend the alpha bitmap with the alpha virtual device
             if (mpAlphaVDev)
             {
                 Bitmap aAlphaBitmap( mpAlphaVDev->GetBitmap( aRelPt, aOutSz ) 
);
-                if (aAlphaBitmap.ImplGetImpBitmap())
+                if (aAlphaBitmap.ImplGetSalBitmap())
                 {
-                    SalBitmap* pSalAlphaBmp2 = 
aAlphaBitmap.ImplGetImpBitmap()->ImplGetSalBitmap();
+                    SalBitmap* pSalAlphaBmp2 = 
aAlphaBitmap.ImplGetSalBitmap().get();
                     if (mpGraphics->BlendAlphaBitmap(aTR, *pSalSrcBmp, 
*pSalAlphaBmp, *pSalAlphaBmp2, this))
                     {
                         mpAlphaVDev->BlendBitmap(aTR, rAlpha);
@@ -953,7 +950,7 @@ void OutputDevice::DrawDeviceAlphaBitmapSlowPath(const 
Bitmap& rBitmap,
     // since we later use it (in nDstWidth/Height) for pixel
     // access)
     // #i38887# reading from screen may sometimes fail
-    if (aBmp.ImplGetImpBitmap())
+    if (aBmp.ImplGetSalBitmap())
     {
         aDstRect.SetSize(aBmp.GetSizePixel());
     }
@@ -982,7 +979,7 @@ void OutputDevice::DrawDeviceAlphaBitmapSlowPath(const 
Bitmap& rBitmap,
                 "OutputDevice::ImplDrawAlpha(): non-8bit alpha no longer 
supported!" );
 
     // #i38887# reading from screen may sometimes fail
-    if (aBmp.ImplGetImpBitmap())
+    if (aBmp.ImplGetSalBitmap())
     {
         Bitmap aNewBitmap;
 
@@ -1057,18 +1054,18 @@ bool OutputDevice::DrawTransformBitmapExDirect(
     const basegfx::B2DPoint aNull(aFullTransform * basegfx::B2DPoint(0.0, 
0.0));
     const basegfx::B2DPoint aTopX(aFullTransform * basegfx::B2DPoint(1.0, 
0.0));
     const basegfx::B2DPoint aTopY(aFullTransform * basegfx::B2DPoint(0.0, 
1.0));
-    SalBitmap* pSalSrcBmp = 
rBitmapEx.GetBitmap().ImplGetImpBitmap()->ImplGetSalBitmap();
+    SalBitmap* pSalSrcBmp = rBitmapEx.GetBitmap().ImplGetSalBitmap().get();
     SalBitmap* pSalAlphaBmp = nullptr;
 
     if(rBitmapEx.IsTransparent())
     {
         if(rBitmapEx.IsAlpha())
         {
-            pSalAlphaBmp = 
rBitmapEx.GetAlpha().ImplGetImpBitmap()->ImplGetSalBitmap();
+            pSalAlphaBmp = rBitmapEx.GetAlpha().ImplGetSalBitmap().get();
         }
         else
         {
-            pSalAlphaBmp = 
rBitmapEx.GetMask().ImplGetImpBitmap()->ImplGetSalBitmap();
+            pSalAlphaBmp = rBitmapEx.GetMask().ImplGetSalBitmap().get();
         }
     }
 
@@ -1385,7 +1382,7 @@ void OutputDevice::BlendBitmap(
             const SalTwoRect&   rPosAry,
             const Bitmap&       rBmp )
 {
-    mpGraphics->BlendBitmap( rPosAry, 
*rBmp.ImplGetImpBitmap()->ImplGetSalBitmap(), this );
+    mpGraphics->BlendBitmap( rPosAry, *rBmp.ImplGetSalBitmap(), this );
 }
 
 Bitmap OutputDevice::BlendBitmapWithAlpha(
diff --git a/vcl/source/outdev/mask.cxx b/vcl/source/outdev/mask.cxx
index afc235743ae9..8677e06174a0 100644
--- a/vcl/source/outdev/mask.cxx
+++ b/vcl/source/outdev/mask.cxx
@@ -26,7 +26,7 @@
 #include <vcl/window.hxx>
 
 #include <salgdi.hxx>
-#include <impbmp.hxx>
+#include <salbmp.hxx>
 #include <outdata.hxx>
 
 void OutputDevice::DrawMask( const Point& rDestPt,
@@ -108,7 +108,7 @@ void OutputDevice::DrawDeviceMask( const Bitmap& rMask, 
const Color& rMaskColor,
 {
     assert(!is_double_buffered_window());
 
-    const std::shared_ptr<ImpBitmap>& xImpBmp = rMask.ImplGetImpBitmap();
+    const std::shared_ptr<SalBitmap>& xImpBmp = rMask.ImplGetSalBitmap();
     if (xImpBmp)
     {
         SalTwoRect aPosAry(rSrcPtPixel.X(), rSrcPtPixel.Y(), 
rSrcSizePixel.Width(), rSrcSizePixel.Height(),
@@ -127,12 +127,11 @@ void OutputDevice::DrawDeviceMask( const Bitmap& rMask, 
const Color& rMaskColor,
             {
                 Bitmap aTmp( rMask );
                 aTmp.Mirror( nMirrFlags );
-                mpGraphics->DrawMask( aPosAry, 
*aTmp.ImplGetImpBitmap()->ImplGetSalBitmap(),
+                mpGraphics->DrawMask( aPosAry, *aTmp.ImplGetSalBitmap(),
                                       rMaskColor, this);
             }
             else
-                mpGraphics->DrawMask( aPosAry, *xImpBmp->ImplGetSalBitmap(),
-                                      rMaskColor, this );
+                mpGraphics->DrawMask( aPosAry, *xImpBmp, rMaskColor, this );
 
         }
     }
diff --git a/vcl/source/window/introwin.cxx b/vcl/source/window/introwin.cxx
index d33a36c5bb14..78a4ce0b31a1 100644
--- a/vcl/source/window/introwin.cxx
+++ b/vcl/source/window/introwin.cxx
@@ -21,7 +21,6 @@
 #include <vcl/bitmap.hxx>
 #include <vcl/introwin.hxx>
 
-#include <impbmp.hxx>
 #include <svdata.hxx>
 #include <salframe.hxx>
 
diff --git a/vcl/source/window/window2.cxx b/vcl/source/window/window2.cxx
index b01defb887f0..57ce81e51464 100644
--- a/vcl/source/window/window2.cxx
+++ b/vcl/source/window/window2.cxx
@@ -38,7 +38,6 @@
 #include <fontinstance.hxx>
 #include <outdev.h>
 #include <svdata.hxx>
-#include <impbmp.hxx>
 #include <salbmp.hxx>
 #include <salgdi.hxx>
 #include <salframe.hxx>
diff --git a/vcl/unx/generic/window/salframe.cxx 
b/vcl/unx/generic/window/salframe.cxx
index 8f8bc056e054..88a9c455cbb1 100644
--- a/vcl/unx/generic/window/salframe.cxx
+++ b/vcl/unx/generic/window/salframe.cxx
@@ -69,7 +69,6 @@
 #include <svdata.hxx>
 #include <strings.hrc>
 #include <bitmaps.hlst>
-#include <impbmp.hxx>
 
 #include <boost/optional.hpp>
 
@@ -334,7 +333,7 @@ static bool lcl_SelectAppIconPixmap( SalDisplay const 
*pDisplay, SalX11Screen nX
         return false;
 
     X11SalBitmap *pBitmap = dynamic_cast < X11SalBitmap * >
-        (aIcon.ImplGetBitmapImpBitmap()->ImplGetSalBitmap());
+        (aIcon.ImplGetBitmapSalBitmap().get());
     if (!pBitmap) // FIXME: opengl
         return false;
 
@@ -374,7 +373,7 @@ static bool lcl_SelectAppIconPixmap( SalDisplay const 
*pDisplay, SalX11Screen nX
         aMask.Invert();
 
         X11SalBitmap *pMask = static_cast < X11SalBitmap * >
-            (aMask.ImplGetImpBitmap()->ImplGetSalBitmap());
+            (aMask.ImplGetSalBitmap().get());
 
         pMask->ImplDraw(icon_mask, nXScreen, 1, aRect, aMonoGC);
         XFreeGC( pDisplay->GetDisplay(), aMonoGC );
diff --git a/vcl/unx/gtk/gtksalframe.cxx b/vcl/unx/gtk/gtksalframe.cxx
index 78bfae5559e4..9fd86abccc3d 100644
--- a/vcl/unx/gtk/gtksalframe.cxx
+++ b/vcl/unx/gtk/gtksalframe.cxx
@@ -53,7 +53,6 @@
 
 #include <dlfcn.h>
 #include <vcl/salbtype.hxx>
-#include <impbmp.hxx>
 #include <window.h>
 #include <strings.hrc>
 #include <bitmaps.hlst>
diff --git a/vcl/unx/gtk3/gtk3gtkframe.cxx b/vcl/unx/gtk3/gtk3gtkframe.cxx
index 63ac768836ed..1db3a469973f 100644
--- a/vcl/unx/gtk3/gtk3gtkframe.cxx
+++ b/vcl/unx/gtk3/gtk3gtkframe.cxx
@@ -59,7 +59,6 @@
 
 #include <dlfcn.h>
 #include <vcl/salbtype.hxx>
-#include <impbmp.hxx>
 #include <window.h>
 #include <strings.hrc>
 #include <bitmaps.hlst>
diff --git a/vcl/win/window/salframe.cxx b/vcl/win/window/salframe.cxx
index 5b5c55198d9a..a15e6924b963 100644
--- a/vcl/win/window/salframe.cxx
+++ b/vcl/win/window/salframe.cxx
@@ -64,7 +64,6 @@
 #include <win/saltimer.h>
 
 #include <helpwin.hxx>
-#include <impbmp.hxx>
 #include <window.h>
 #include <sallayout.hxx>
 
@@ -4543,7 +4542,7 @@ static LRESULT ImplDrawItem(HWND, WPARAM wParam, LPARAM 
lParam )
             aBitmap.Replace( COL_LIGHTMAGENTA,
                 Color( 
GetRValue(colBackground),GetGValue(colBackground),GetBValue(colBackground) ));
 
-            WinSalBitmap* pSalBmp = 
static_cast<WinSalBitmap*>(aBitmap.ImplGetImpBitmap()->ImplGetSalBitmap());
+            WinSalBitmap* pSalBmp = 
static_cast<WinSalBitmap*>(aBitmap.ImplGetSalBitmap().get());
             HGLOBAL hDrawDIB = pSalBmp->ImplGethDIB();
 
             if( hDrawDIB )
diff --git a/vcl/win/window/salmenu.cxx b/vcl/win/window/salmenu.cxx
index 45be022ef23b..1339f80afa3d 100644
--- a/vcl/win/window/salmenu.cxx
+++ b/vcl/win/window/salmenu.cxx
@@ -29,7 +29,6 @@
 #include <win/salframe.h>
 #include <win/salmenu.h>
 
-#include <impbmp.hxx>
 #include <salgdi.hxx>
 
 static DWORD myerr=0;
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to