mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-31 20:40:47 +00:00
Correction for issue with gcc 3.4.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@20243 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
99d3699240
commit
9b989ee999
3 changed files with 39 additions and 14 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
2004-10-22 08:26 Gregory John Casamento <greg_casamento@yahoo.com>
|
||||||
|
|
||||||
|
* Source/NSStepperCell.m: Corrected issue with [NSStepperCell
|
||||||
|
initWithCoder:] for encoding issue with gcc 3.4.
|
||||||
|
* Header/AppKit/NSStepperCell.h: Took out defines which use
|
||||||
|
the bitfields in NSCell.h. These now are BOOL variables.
|
||||||
|
|
||||||
2004-10-21 Fred Kiefer <FredKiefer@gmx.de>
|
2004-10-21 Fred Kiefer <FredKiefer@gmx.de>
|
||||||
|
|
||||||
* Source/NSResponder.m (-initWithCoder:): Set missing default
|
* Source/NSResponder.m (-initWithCoder:): Set missing default
|
||||||
|
|
|
@ -32,15 +32,13 @@
|
||||||
|
|
||||||
@interface NSStepperCell : NSActionCell <NSCoding>
|
@interface NSStepperCell : NSActionCell <NSCoding>
|
||||||
{
|
{
|
||||||
// Think of the following ones as of two BOOL ivars
|
|
||||||
#define _autorepeat _cell.subclass_bool_one
|
|
||||||
#define _valueWraps _cell.subclass_bool_two
|
|
||||||
|
|
||||||
double _maxValue;
|
double _maxValue;
|
||||||
double _minValue;
|
double _minValue;
|
||||||
double _increment;
|
double _increment;
|
||||||
BOOL highlightUp;
|
BOOL highlightUp;
|
||||||
BOOL highlightDown;
|
BOOL highlightDown;
|
||||||
|
BOOL _autorepeat;
|
||||||
|
BOOL _valueWraps;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (double)maxValue;
|
- (double)maxValue;
|
||||||
|
|
|
@ -341,22 +341,42 @@ static inline void HighlightDownButton(NSRect aRect)
|
||||||
//
|
//
|
||||||
- (void) encodeWithCoder: (NSCoder*)aCoder
|
- (void) encodeWithCoder: (NSCoder*)aCoder
|
||||||
{
|
{
|
||||||
BOOL tmp1, tmp2;
|
int tmp1, tmp2;
|
||||||
[super encodeWithCoder: aCoder];
|
[super encodeWithCoder: aCoder];
|
||||||
tmp1 = _autorepeat;
|
|
||||||
tmp2 = _valueWraps;
|
tmp1 = (int)_autorepeat;
|
||||||
[aCoder encodeValuesOfObjCTypes: "dddii",
|
tmp2 = (int)_valueWraps;
|
||||||
&_maxValue, &_minValue, &_increment, &tmp1, &tmp2];
|
|
||||||
|
[aCoder encodeValueOfObjCType: @encode(double)
|
||||||
|
at: &_maxValue];
|
||||||
|
[aCoder encodeValueOfObjCType: @encode(double)
|
||||||
|
at: &_minValue];
|
||||||
|
[aCoder encodeValueOfObjCType: @encode(double)
|
||||||
|
at: &_increment];
|
||||||
|
[aCoder encodeValueOfObjCType: @encode(int)
|
||||||
|
at: &tmp1];
|
||||||
|
[aCoder encodeValueOfObjCType: @encode(int)
|
||||||
|
at: &tmp2];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (id) initWithCoder: (NSCoder*)aDecoder
|
- (id) initWithCoder: (NSCoder*)aDecoder
|
||||||
{
|
{
|
||||||
BOOL tmp1, tmp2;
|
int tmp1, tmp2;
|
||||||
[super initWithCoder: aDecoder];
|
[super initWithCoder: aDecoder];
|
||||||
[aDecoder decodeValuesOfObjCTypes: "dddii",
|
|
||||||
&_maxValue, &_minValue, &_increment, &tmp1, &tmp2];
|
[aDecoder decodeValueOfObjCType: @encode(double)
|
||||||
_autorepeat = tmp1;
|
at: &_maxValue];
|
||||||
_valueWraps = tmp2;
|
[aDecoder decodeValueOfObjCType: @encode(double)
|
||||||
|
at: &_minValue];
|
||||||
|
[aDecoder decodeValueOfObjCType: @encode(double)
|
||||||
|
at: &_increment];
|
||||||
|
[aDecoder decodeValueOfObjCType: @encode(int)
|
||||||
|
at: &tmp1];
|
||||||
|
[aDecoder decodeValueOfObjCType: @encode(int)
|
||||||
|
at: &tmp2];
|
||||||
|
|
||||||
|
_autorepeat = (BOOL)tmp1;
|
||||||
|
_valueWraps = (BOOL)tmp2;
|
||||||
|
|
||||||
return self;
|
return self;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue