summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorJens-Heiner Rechtien <hr@openoffice.org>2004-10-13 07:57:05 +0000
committerJens-Heiner Rechtien <hr@openoffice.org>2004-10-13 07:57:05 +0000
commit5c173d7bb81b1913d59e74cf8c09971451162fd3 (patch)
tree67acffbb070a573f303f538dcfe263f0a4bd6c72 /vcl
parent9e76b7615a46093f0c8ddebb274da43d2d1745e3 (diff)
INTEGRATION: CWS vcl27 (1.195.36); FILE MERGED
2004/09/17 15:09:33 pl 1.195.36.2: RESYNC: (1.195-1.199); FILE MERGED 2004/09/08 14:01:49 ssa 1.195.36.1: #i30861# #i30335# correct invalidate handling for transparent windows
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/window/window.cxx27
1 files changed, 23 insertions, 4 deletions
diff --git a/vcl/source/window/window.cxx b/vcl/source/window/window.cxx
index 41585c5fc6d5..eeb1488641f3 100644
--- a/vcl/source/window/window.cxx
+++ b/vcl/source/window/window.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: window.cxx,v $
*
- * $Revision: 1.199 $
+ * $Revision: 1.200 $
*
- * last change: $Author: obo $ $Date: 2004-09-09 16:23:08 $
+ * last change: $Author: hr $ $Date: 2004-10-13 08:57:05 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -2590,7 +2590,23 @@ void Window::ImplInvalidateFrameRegion( const Region* pRegion, USHORT nFlags )
if ( !(mnPaintFlags & IMPL_PAINT_PAINTALL) )
maInvalidateRegion.Union( *pRegion );
- ImplPostPaint();
+ // Handle transparent windows correctly: invalidate must be done on the first opaque parent
+ if( ((IsPaintTransparent() && !(nFlags & INVALIDATE_NOTRANSPARENT)) || (nFlags & INVALIDATE_TRANSPARENT) )
+ && ImplGetParent() )
+ {
+ /* The following optimization shows problems when resizing (native) tabcontrols (eg the Help viewer)
+ So we pass a NULL region to the parent as well which will result in a IMPL_PAINT_PAINTALL on the parent...
+
+ Region aWindowRegion;
+ if( pRegion == NULL )
+ // compute real region to avoid full repaint in parent
+ aWindowRegion = Rectangle( Point( mnOutOffX, mnOutOffY ), Size( mnOutWidth, mnOutHeight ) );
+ ImplGetParent()->ImplInvalidateFrameRegion( pRegion==NULL ? &aWindowRegion : pRegion, nFlags );
+ */
+ ImplGetParent()->ImplInvalidateFrameRegion( pRegion, nFlags );
+ }
+ else
+ ImplPostPaint();
}
// -----------------------------------------------------------------------
@@ -2621,7 +2637,10 @@ void Window::ImplInvalidateParentFrameRegion( Region& rRegion )
if ( mbOverlapWin )
mpFrameWindow->ImplInvalidateOverlapFrameRegion( rRegion );
else
- ImplGetParent()->ImplInvalidateFrameRegion( &rRegion, INVALIDATE_CHILDREN );
+ {
+ if( ImplGetParent() )
+ ImplGetParent()->ImplInvalidateFrameRegion( &rRegion, INVALIDATE_CHILDREN );
+ }
}
// -----------------------------------------------------------------------