mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-06-04 13:00:41 +00:00
Removed minor optimisation in favor of compatibility
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@5198 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
96daaf4ce0
commit
fb93aad837
4 changed files with 21 additions and 16 deletions
|
@ -1,3 +1,9 @@
|
||||||
|
Tue Nov 16 10:49:00 1999 Richard Frith-Macdonald <richard@brainstorm.co.uk>
|
||||||
|
|
||||||
|
* 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 <richard@brainstorm.co.uk>
|
Tue Nov 16 7:05:00 1999 Richard Frith-Macdonald <richard@brainstorm.co.uk>
|
||||||
|
|
||||||
* Source/NSApplication.m: ([-run]) make sure user defaults are
|
* Source/NSApplication.m: ([-run]) make sure user defaults are
|
||||||
|
|
|
@ -50,16 +50,16 @@
|
||||||
* This caching assumes that the value returned by [-isFlipped] will
|
* This caching assumes that the value returned by [-isFlipped] will
|
||||||
* not change during the views lifetime - if it does, the view must
|
* not change during the views lifetime - if it does, the view must
|
||||||
* be sure to change the flag accordingly.
|
* be sure to change the flag accordingly.
|
||||||
* 'opaque_view' is similar.
|
|
||||||
*/
|
*/
|
||||||
unsigned flipped_view:1;
|
unsigned flipped_view:1;
|
||||||
unsigned has_subviews:1; /* This view has subviews */
|
unsigned has_subviews:1; /* The view has subviews. */
|
||||||
unsigned has_currects:1; /* This view has cursor rects */
|
unsigned has_currects:1; /* The view has cursor rects. */
|
||||||
unsigned has_trkrects:1; /* This view has tracking rects */
|
unsigned has_trkrects:1; /* The view has tracking rects. */
|
||||||
unsigned has_draginfo:1; /* View/window has drag types */
|
unsigned has_draginfo:1; /* View/window has drag types. */
|
||||||
unsigned opaque_view:1;
|
unsigned opaque_view:1; /* For views whose opacity may */
|
||||||
unsigned valid_rects:1; /* Some cursor rects are valid */
|
/* change to keep track of it. */
|
||||||
unsigned needs_display:1; /* window/view needs display */
|
unsigned valid_rects:1; /* Some cursor rects may be ok. */
|
||||||
|
unsigned needs_display:1; /* Window/view needs display. */
|
||||||
} _rFlags;
|
} _rFlags;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1023,7 +1023,6 @@ void __dummy_GMAppKit_functionForLinking() {}
|
||||||
|
|
||||||
#ifdef GNU_GUI_LIBRARY
|
#ifdef GNU_GUI_LIBRARY
|
||||||
_rFlags.flipped_view = [self isFlipped];
|
_rFlags.flipped_view = [self isFlipped];
|
||||||
_rFlags.opaque_view = [self isOpaque];
|
|
||||||
if ([sub_views count])
|
if ([sub_views count])
|
||||||
_rFlags.has_subviews = 1;
|
_rFlags.has_subviews = 1;
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -230,7 +230,6 @@ GSSetDragTypes(NSView* obj, NSArray *types)
|
||||||
_previousKeyView = nil;
|
_previousKeyView = nil;
|
||||||
|
|
||||||
_rFlags.flipped_view = [self isFlipped];
|
_rFlags.flipped_view = [self isFlipped];
|
||||||
_rFlags.opaque_view = [self isOpaque];
|
|
||||||
|
|
||||||
return self;
|
return self;
|
||||||
}
|
}
|
||||||
|
@ -361,8 +360,10 @@ GSSetDragTypes(NSView* obj, NSArray *types)
|
||||||
|
|
||||||
while (next != nil)
|
while (next != nil)
|
||||||
{
|
{
|
||||||
if (current->_rFlags.opaque_view)
|
if ([current isOpaque] == YES)
|
||||||
|
{
|
||||||
break;
|
break;
|
||||||
|
}
|
||||||
current = next;
|
current = next;
|
||||||
next = current->super_view;
|
next = current->super_view;
|
||||||
}
|
}
|
||||||
|
@ -1348,7 +1349,7 @@ GSSetDragTypes(NSView* obj, NSArray *types)
|
||||||
{
|
{
|
||||||
if (_rFlags.needs_display)
|
if (_rFlags.needs_display)
|
||||||
{
|
{
|
||||||
if (_rFlags.opaque_view)
|
if ([self isOpaque] == YES)
|
||||||
{
|
{
|
||||||
[self displayIfNeededIgnoringOpacity];
|
[self displayIfNeededIgnoringOpacity];
|
||||||
}
|
}
|
||||||
|
@ -1407,7 +1408,7 @@ GSSetDragTypes(NSView* obj, NSArray *types)
|
||||||
{
|
{
|
||||||
if (_rFlags.needs_display)
|
if (_rFlags.needs_display)
|
||||||
{
|
{
|
||||||
if (_rFlags.opaque_view)
|
if ([self isOpaque] == YES)
|
||||||
{
|
{
|
||||||
[self displayIfNeededInRectIgnoringOpacity: aRect];
|
[self displayIfNeededInRectIgnoringOpacity: aRect];
|
||||||
}
|
}
|
||||||
|
@ -1518,7 +1519,7 @@ GSSetDragTypes(NSView* obj, NSArray *types)
|
||||||
|
|
||||||
- (void) displayRect: (NSRect)rect
|
- (void) displayRect: (NSRect)rect
|
||||||
{
|
{
|
||||||
if (_rFlags.opaque_view)
|
if ([self isOpaque] == YES)
|
||||||
{
|
{
|
||||||
[self displayRectIgnoringOpacity: rect];
|
[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.
|
* Keep a note of whether this is a flipped view or not.
|
||||||
*/
|
*/
|
||||||
_rFlags.flipped_view = [self isFlipped];
|
_rFlags.flipped_view = [self isFlipped];
|
||||||
_rFlags.opaque_view = [self isOpaque];
|
|
||||||
|
|
||||||
if ([sub_views count])
|
if ([sub_views count])
|
||||||
_rFlags.has_subviews = 1;
|
_rFlags.has_subviews = 1;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue