mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-06-02 19:30:59 +00:00
Added some more keyed decoding.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@20211 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
00a434e4a0
commit
67b2f51063
5 changed files with 217 additions and 73 deletions
|
@ -368,12 +368,24 @@ static NSColor *shadowCol;
|
|||
BOOL tmp;
|
||||
|
||||
[super initWithCoder: aDecoder];
|
||||
|
||||
[aDecoder decodeValueOfObjCType: @encode(BOOL) at: &tmp];
|
||||
_formcell_auto_title_width = tmp;
|
||||
[aDecoder decodeValueOfObjCType: @encode(float) at: &_displayedTitleWidth];
|
||||
[aDecoder decodeValueOfObjCType: @encode(id)
|
||||
at: &_titleCell];
|
||||
if ([aDecoder allowsKeyedCoding])
|
||||
{
|
||||
if ([aDecoder containsValueForKey: @"NSTitleWidth"])
|
||||
{
|
||||
[self setTitleWidth: [aDecoder decodeFloatForKey: @"NSTitleWidth"]];
|
||||
}
|
||||
if ([aDecoder containsValueForKey: @"NSTitleCell"])
|
||||
{
|
||||
ASSIGN(_titleCell, [aDecoder decodeObjectForKey: @"NSTitleCell"]);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
[aDecoder decodeValueOfObjCType: @encode(BOOL) at: &tmp];
|
||||
_formcell_auto_title_width = tmp;
|
||||
[aDecoder decodeValueOfObjCType: @encode(float) at: &_displayedTitleWidth];
|
||||
[aDecoder decodeValueOfObjCType: @encode(id) at: &_titleCell];
|
||||
}
|
||||
return self;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue