[Libreoffice-commits] core.git: include/vcl vcl/source

Chris Sherlock chris.sherlock79 at gmail.com
Mon Nov 10 17:58:28 PST 2014


 include/vcl/outdev.hxx         |    2 --
 include/vcl/window.hxx         |    4 ++++
 vcl/source/outdev/outdev.cxx   |   10 ----------
 vcl/source/window/clipping.cxx |    8 ++++----
 vcl/source/window/window.cxx   |    8 ++++++++
 5 files changed, 16 insertions(+), 16 deletions(-)

New commits:
commit df2dbdc283a5af85e7250e4ba94ba8dfef96932b
Author: Chris Sherlock <chris.sherlock79 at gmail.com>
Date:   Mon Nov 10 23:12:52 2014 +1100

    vcl: move OutputDevice::ImplGetFrameDev() to Window
    
    ImplGetFrameDev() is for some unknown reason in OutputDevice, but it's
    most definitely something that's specific to Window. I've moved this, and
    also renamed it getFrameDev() as it's a private function.
    
    Change-Id: Iffb2c439bee8c29ee585a0d50cfd6fbcfc28c3bc
    Reviewed-on: https://gerrit.libreoffice.org/12338
    Reviewed-by: Chris Sherlock <chris.sherlock79 at gmail.com>
    Tested-by: Chris Sherlock <chris.sherlock79 at gmail.com>

diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx
index 80d8576..a977936 100644
--- a/include/vcl/outdev.hxx
+++ b/include/vcl/outdev.hxx
@@ -487,8 +487,6 @@ public:
 
 private:
 
-    SAL_DLLPRIVATE void         ImplGetFrameDev     ( const Point& rPt, const Point& rDevPt, const Size& rDevSize,
-                                                      OutputDevice& rOutDev );
     SAL_DLLPRIVATE void         ImplDrawFrameDev    ( const Point& rPt, const Point& rDevPt, const Size& rDevSize,
                                                       const OutputDevice& rOutDev, const vcl::Region& rRegion );
     ///@}
diff --git a/include/vcl/window.hxx b/include/vcl/window.hxx
index fc6bc06..2e072ba 100644
--- a/include/vcl/window.hxx
+++ b/include/vcl/window.hxx
@@ -533,10 +533,14 @@ protected:
 
     SAL_DLLPRIVATE void                 PushPaintHelper(PaintHelper *pHelper);
     SAL_DLLPRIVATE void                 PopPaintHelper(PaintHelper *pHelper);
+
 private:
 
     SAL_DLLPRIVATE void                 ImplInitWindowData( WindowType nType );
 
+    SAL_DLLPRIVATE void                 getFrameDev( const Point& rPt, const Point& rDevPt, const Size& rDevSize,
+                                                         OutputDevice& rOutDev );
+
     SAL_DLLPRIVATE void                 ImplSetFrameParent( const vcl::Window* pParent );
 
     SAL_DLLPRIVATE void                 ImplInsertWindow( vcl::Window* pParent );
diff --git a/vcl/source/outdev/outdev.cxx b/vcl/source/outdev/outdev.cxx
index ad7779d..e7ec624 100644
--- a/vcl/source/outdev/outdev.cxx
+++ b/vcl/source/outdev/outdev.cxx
@@ -398,16 +398,6 @@ bool OutputDevice::SupportsOperation( OutDevSupportType eType ) const
 
 // Frame public functions
 
-void OutputDevice::ImplGetFrameDev( const Point& rPt, const Point& rDevPt, const Size& rDevSize,
-                                    OutputDevice& rDev )
-{
-
-    bool bOldMap = mbMap;
-    mbMap = false;
-    rDev.DrawOutDev( rDevPt, rDevSize, rPt, rDevSize, *this );
-    mbMap = bOldMap;
-}
-
 void OutputDevice::ImplDrawFrameDev( const Point& rPt, const Point& rDevPt, const Size& rDevSize,
                                      const OutputDevice& rOutDev, const vcl::Region& rRegion )
 {
diff --git a/vcl/source/window/clipping.cxx b/vcl/source/window/clipping.cxx
index 42b2c92..d3e40d9 100644
--- a/vcl/source/window/clipping.cxx
+++ b/vcl/source/window/clipping.cxx
@@ -854,10 +854,10 @@ void Window::ImplSaveOverlapBackground()
                     mpWindowImpl->mpFrameData->mnAllSaveBackSize += nSaveBackSize;
                     Point aDevPt;
 
-                    OutputDevice *pOutDev = mpWindowImpl->mpFrameWindow->GetOutDev();
-                    pOutDev->ImplGetFrameDev( Point( mnOutOffX, mnOutOffY ),
-                                              aDevPt, aOutSize,
-                                              *(mpWindowImpl->mpOverlapData->mpSaveBackDev) );
+                    Window* pWin = mpWindowImpl->mpFrameWindow;
+                    pWin->getFrameDev( Point( mnOutOffX, mnOutOffY ),
+                                           aDevPt, aOutSize,
+                                           *(mpWindowImpl->mpOverlapData->mpSaveBackDev) );
                     mpWindowImpl->mpOverlapData->mpNextBackWin = mpWindowImpl->mpFrameData->mpFirstBackWin;
                     mpWindowImpl->mpFrameData->mpFirstBackWin = this;
                 }
diff --git a/vcl/source/window/window.cxx b/vcl/source/window/window.cxx
index 3691241..737eeb9 100644
--- a/vcl/source/window/window.cxx
+++ b/vcl/source/window/window.cxx
@@ -1196,6 +1196,14 @@ void Window::ImplInitWindowData( WindowType nType )
     mbEnableRTL         = Application::GetSettings().GetLayoutRTL();         // true: this outdev will be mirrored if RTL window layout (UI mirroring) is globally active
 }
 
+void Window::getFrameDev( const Point& rPt, const Point& rDevPt, const Size& rDevSize, OutputDevice& rDev )
+{
+    bool bOldMap = mbMap;
+    mbMap = false;
+    rDev.DrawOutDev( rDevPt, rDevSize, rPt, rDevSize, *this );
+    mbMap = bOldMap;
+}
+
 ImplWinData* Window::ImplGetWinData() const
 {
     if ( !mpWindowImpl->mpWinData )


More information about the Libreoffice-commits mailing list