diff options
author | Chris Sherlock <chris.sherlock79@gmail.com> | 2014-06-02 00:28:43 +1000 |
---|---|---|
committer | Chris Sherlock <chris.sherlock79@gmail.com> | 2014-07-19 23:40:48 +1000 |
commit | a5382f722ebba25944aef13ed562fa23045577f3 (patch) | |
tree | 2651ba36e4012ad90963b6e65b4b0c58ee416d10 | |
parent | 4e90e2f710580376274e8eb043e3efb18fe419e3 (diff) |
vcl: move ImplExcludeOverlapWindows() to ClipManager
Change-Id: I50c2e7d27c7ce706ef926fe9ce90503617c7df30
-rw-r--r-- | include/vcl/window.hxx | 2 | ||||
-rw-r--r-- | vcl/inc/clipmgr.hxx | 1 | ||||
-rw-r--r-- | vcl/source/window/clipmgr.cxx | 21 | ||||
-rw-r--r-- | vcl/source/window/clipping.cxx | 15 |
4 files changed, 19 insertions, 20 deletions
diff --git a/include/vcl/window.hxx b/include/vcl/window.hxx index 490c5fd1c69b..9026f060b3ad 100644 --- a/include/vcl/window.hxx +++ b/include/vcl/window.hxx @@ -522,8 +522,6 @@ private: SAL_DLLPRIVATE void ImplUpdateSysObjClip(); SAL_DLLPRIVATE void ImplIntersectWindowRegion( Region& rRegion ); - SAL_DLLPRIVATE void ImplExcludeWindowRegion( Region& rRegion ); - SAL_DLLPRIVATE void ImplExcludeOverlapWindows( Region& rRegion ); SAL_DLLPRIVATE bool ImplClipChildren( Region& rRegion ); SAL_DLLPRIVATE void ImplClipAllChildren( Region& rRegion ); diff --git a/vcl/inc/clipmgr.hxx b/vcl/inc/clipmgr.hxx index a514f67d645b..7c73a28f3227 100644 --- a/vcl/inc/clipmgr.hxx +++ b/vcl/inc/clipmgr.hxx @@ -37,6 +37,7 @@ private: void clipSiblings( Window* pWindow, Region& rRegion ); void intersectClipRegion( Window* pWindow, Region& rRegion ); + void excludeOverlapWindows( Window *pWindow, Region& rRegion ); public: ~ClipManager() { instanceFlag = false; } diff --git a/vcl/source/window/clipmgr.cxx b/vcl/source/window/clipmgr.cxx index c7a74c52bef5..0d48fc4e3988 100644 --- a/vcl/source/window/clipmgr.cxx +++ b/vcl/source/window/clipmgr.cxx @@ -92,14 +92,14 @@ void ClipManager::ClipBoundaries( Window* pWindow, Region& rRegion, bool bThis, if ( pWindow->mpWindowImpl->mbReallyVisible ) pWindow->ImplExcludeWindowRegion( rRegion ); - ImplExcludeOverlapWindows( rRegion ); + excludeOverlapWindows( pWindow, rRegion ); pOverlapWindow = pOverlapWindow->mpWindowImpl->mpNext; } pStartOverlapWindow = pStartOverlapWindow->mpWindowImpl->mpOverlapWindow; } - // Clip Child Overlap Windows - pWindow->ImplExcludeOverlapWindows( rRegion ); + // Clip child overlap windows + excludeOverlapWindows( pWindow, rRegion ); } } else @@ -108,6 +108,21 @@ void ClipManager::ClipBoundaries( Window* pWindow, Region& rRegion, bool bThis, } } +void ClipManager::excludeOverlapWindows( Window *pWindow, Region& rRegion ) +{ + Window* pOverlapWindow = pWindow->mpWindowImpl->mpFirstOverlap; + while ( pOverlapWindow ) + { + if ( pOverlapWindow->mpWindowImpl->mbReallyVisible ) + { + pOverlapWindow->ImplExcludeWindowRegion( rRegion ); + excludeOverlapWindows( pOverlapWindow, rRegion ); + } + + pOverlapWindow = pOverlapWindow->mpWindowImpl->mpNext; + } +} + void ClipManager::intersectClipRegion( Window* pWindow, Region& rRegion ) { ClipManager *clipMgr = ClipManager::GetInstance(); diff --git a/vcl/source/window/clipping.cxx b/vcl/source/window/clipping.cxx index c824dc824559..7c5eab3306bb 100644 --- a/vcl/source/window/clipping.cxx +++ b/vcl/source/window/clipping.cxx @@ -492,21 +492,6 @@ void Window::ImplExcludeWindowRegion( Region& rRegion ) } } -void Window::ImplExcludeOverlapWindows( Region& rRegion ) -{ - Window* pWindow = mpWindowImpl->mpFirstOverlap; - while ( pWindow ) - { - if ( pWindow->mpWindowImpl->mbReallyVisible ) - { - pWindow->ImplExcludeWindowRegion( rRegion ); - pWindow->ImplExcludeOverlapWindows( rRegion ); - } - - pWindow = pWindow->mpWindowImpl->mpNext; - } -} - void Window::ImplIntersectAndUnionOverlapWindows( const Region& rInterRegion, Region& rRegion ) { Window* pWindow = mpWindowImpl->mpFirstOverlap; |