* Source/NSProgressIndicator.m (-encodeWithCoder:, initWithCoder:)

The flag isDisplayedWhenStopped is stored negated.
Should fix bug #34487


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@33947 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
fredkiefer 2011-10-06 08:47:59 +00:00
parent 323e837d9a
commit d4edc7228e
2 changed files with 8 additions and 3 deletions

View file

@ -1,3 +1,8 @@
2011-10-06 Fred Kiefer <FredKiefer@gmx.de>
* Source/NSProgressIndicator.m (-encodeWithCoder:, initWithCoder:)
The flag isDisplayedWhenStopped is stored negated.
2011-10-04 Fred Kiefer <FredKiefer@gmx.de> 2011-10-04 Fred Kiefer <FredKiefer@gmx.de>
* Headers/AppKit/NSBezierPath.h, * Headers/AppKit/NSBezierPath.h,
@ -943,7 +948,7 @@
Turn release messages sent to autorelease pools into drain messages. No Turn release messages sent to autorelease pools into drain messages. No
functionality change in non-GC mode, in GC mode it invokes a quick GC pass functionality change in non-GC mode, in GC mode it invokes a quick GC pass
to try to delete the short-lived objects. to try to delete the short-lived objects.
Also deleted some [pool release] lines just before exit() or Also deleted some [pool release] lines just before exit() or
return-from-main statements. These cause objects to be swapped in and return-from-main statements. These cause objects to be swapped in and
destructors to be run to no benefit (the OS will reclaim this memory destructors to be run to no benefit (the OS will reclaim this memory

View file

@ -385,7 +385,7 @@
flags |= 8; flags |= 8;
flags |= (_controlSize == NSSmallControlSize) ? 0x100 : 0; flags |= (_controlSize == NSSmallControlSize) ? 0x100 : 0;
flags |= (_style == NSProgressIndicatorSpinningStyle) ? 0x1000 : 0; flags |= (_style == NSProgressIndicatorSpinningStyle) ? 0x1000 : 0;
flags |= _isDisplayedWhenStopped ? 0x2000 : 0; flags |= _isDisplayedWhenStopped ? 0 : 0x2000;
[aCoder encodeInt: flags forKey: @"NSpiFlags"]; [aCoder encodeInt: flags forKey: @"NSpiFlags"];
// things which Gorm encodes, but IB doesn't care about. // things which Gorm encodes, but IB doesn't care about.
@ -447,7 +447,7 @@
_controlSize = (flags & 0x100) ? NSSmallControlSize : NSRegularControlSize; _controlSize = (flags & 0x100) ? NSSmallControlSize : NSRegularControlSize;
[self setStyle: (flags & 0x1000) ? NSProgressIndicatorSpinningStyle [self setStyle: (flags & 0x1000) ? NSProgressIndicatorSpinningStyle
: NSProgressIndicatorBarStyle]; : NSProgressIndicatorBarStyle];
_isDisplayedWhenStopped = ((flags & 0x2000) == 0x2000); _isDisplayedWhenStopped = ((flags & 0x2000) != 0x2000);
// ignore the rest, since they are not pertinent to GNUstep. // ignore the rest, since they are not pertinent to GNUstep.
} }
else else