diff --git a/ChangeLog b/ChangeLog index 7b9305cc6..b3a931ef6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Tue Nov 16 10:49:00 1999 Richard Frith-Macdonald + + * Source/NSView.m: Removed opaque-view optimisation in favour of + retaining MacOS-X compatibility. + * Source/GMAppKit.m: ditto. + Tue Nov 16 7:05:00 1999 Richard Frith-Macdonald * Source/NSApplication.m: ([-run]) make sure user defaults are diff --git a/Headers/gnustep/gui/NSResponder.h b/Headers/gnustep/gui/NSResponder.h index 5659978a6..fa326c339 100644 --- a/Headers/gnustep/gui/NSResponder.h +++ b/Headers/gnustep/gui/NSResponder.h @@ -50,16 +50,16 @@ * This caching assumes that the value returned by [-isFlipped] will * not change during the views lifetime - if it does, the view must * be sure to change the flag accordingly. - * 'opaque_view' is similar. */ unsigned flipped_view:1; - unsigned has_subviews:1; /* This view has subviews */ - unsigned has_currects:1; /* This view has cursor rects */ - unsigned has_trkrects:1; /* This view has tracking rects */ - unsigned has_draginfo:1; /* View/window has drag types */ - unsigned opaque_view:1; - unsigned valid_rects:1; /* Some cursor rects are valid */ - unsigned needs_display:1; /* window/view needs display */ + unsigned has_subviews:1; /* The view has subviews. */ + unsigned has_currects:1; /* The view has cursor rects. */ + unsigned has_trkrects:1; /* The view has tracking rects. */ + unsigned has_draginfo:1; /* View/window has drag types. */ + unsigned opaque_view:1; /* For views whose opacity may */ + /* change to keep track of it. */ + unsigned valid_rects:1; /* Some cursor rects may be ok. */ + unsigned needs_display:1; /* Window/view needs display. */ } _rFlags; } diff --git a/Model/GMAppKit.m b/Model/GMAppKit.m index e15379af0..2f08e64e1 100644 --- a/Model/GMAppKit.m +++ b/Model/GMAppKit.m @@ -1023,7 +1023,6 @@ void __dummy_GMAppKit_functionForLinking() {} #ifdef GNU_GUI_LIBRARY _rFlags.flipped_view = [self isFlipped]; - _rFlags.opaque_view = [self isOpaque]; if ([sub_views count]) _rFlags.has_subviews = 1; #endif diff --git a/Source/NSView.m b/Source/NSView.m index 08701e6f2..a1b2c2e00 100644 --- a/Source/NSView.m +++ b/Source/NSView.m @@ -230,7 +230,6 @@ GSSetDragTypes(NSView* obj, NSArray *types) _previousKeyView = nil; _rFlags.flipped_view = [self isFlipped]; - _rFlags.opaque_view = [self isOpaque]; return self; } @@ -361,8 +360,10 @@ GSSetDragTypes(NSView* obj, NSArray *types) while (next != nil) { - if (current->_rFlags.opaque_view) - break; + if ([current isOpaque] == YES) + { + break; + } current = next; next = current->super_view; } @@ -1348,7 +1349,7 @@ GSSetDragTypes(NSView* obj, NSArray *types) { if (_rFlags.needs_display) { - if (_rFlags.opaque_view) + if ([self isOpaque] == YES) { [self displayIfNeededIgnoringOpacity]; } @@ -1407,7 +1408,7 @@ GSSetDragTypes(NSView* obj, NSArray *types) { if (_rFlags.needs_display) { - if (_rFlags.opaque_view) + if ([self isOpaque] == YES) { [self displayIfNeededInRectIgnoringOpacity: aRect]; } @@ -1518,7 +1519,7 @@ GSSetDragTypes(NSView* obj, NSArray *types) - (void) displayRect: (NSRect)rect { - if (_rFlags.opaque_view) + if ([self isOpaque] == YES) { [self displayRectIgnoringOpacity: rect]; } @@ -2425,7 +2426,6 @@ static NSView* findByTag(NSView *view, int aTag, unsigned *level) * Keep a note of whether this is a flipped view or not. */ _rFlags.flipped_view = [self isFlipped]; - _rFlags.opaque_view = [self isOpaque]; if ([sub_views count]) _rFlags.has_subviews = 1;