From b5be67ab7d71ff27406e10f13253067dfd110cf4 Mon Sep 17 00:00:00 2001 From: richard Date: Thu, 16 Mar 2000 13:12:50 +0000 Subject: [PATCH] Tidy git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@6290 72102866-910b-0410-8b05-ffd578937521 --- Source/NSView.m | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/Source/NSView.m b/Source/NSView.m index f54e5357d..500246040 100644 --- a/Source/NSView.m +++ b/Source/NSView.m @@ -1625,14 +1625,20 @@ GSSetDragTypes(NSView* obj, NSArray *types) /* * If the rect we displayed contains the _invalidRect or _visibleRect - * then we can empty _invalidRect. If all subviews have been - * fully displayed, so this view no longer needs to be displayed. + * then we can empty _invalidRect. + * If all subviews have been fully displayed, we can also turn off the + * 'needs_display' flag. */ if (NSEqualRects(aRect, NSUnionRect(neededRect, aRect)) == YES) { _invalidRect = NSZeroRect; _rFlags.needs_display = subviewNeedsDisplay; } + if (_rFlags.needs_display == YES + && NSEqualRects(aRect, NSUnionRect(_visibleRect, aRect)) == YES) + { + _rFlags.needs_display = NO; + } [_window flushWindow]; } } @@ -1738,13 +1744,18 @@ GSSetDragTypes(NSView* obj, NSArray *types) /* * If the rect we displayed contains the _invalidRect or _visibleRect * then we can empty _invalidRect. If all subviews have been - * fully displayed, so this view no longer needs to be displayed. + * fully displayed, we can also turn off the 'needs_display' flag. */ if (NSEqualRects(aRect, NSUnionRect(neededRect, aRect)) == YES) { _invalidRect = NSZeroRect; _rFlags.needs_display = subviewNeedsDisplay; } + if (_rFlags.needs_display == YES + && NSEqualRects(aRect, NSUnionRect(_visibleRect, aRect)) == YES) + { + _rFlags.needs_display = NO; + } [_window flushWindow]; }