mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-10-05 16:42:58 +00:00
Sending NS_initWithCoder at the right time
This commit is contained in:
1 parent
05edec8a8b
commit
5e20a6d9ef
1 file changed
+7
-4
@@ -165,7 +165,8 @@ _CPButtonBezelStyleHeights[CPHUDBezelStyle] = 20;
|
||||
|
||||
- (id)initWithCoder:(CPCoder)aCoder
|
||||
{
|
||||
// We need to do a bit of magic to determine if this is a checkbox or radio button.
|
||||
// We need to do a bit of magic to determine if this is a checkbox or radio button
|
||||
// BEFORE we can initialize the rest of the object.
|
||||
var cell = [aCoder decodeObjectForKey:@"NSCell"],
|
||||
alternateImage = [cell alternateImage];
|
||||
|
||||
@@ -181,10 +182,12 @@ _CPButtonBezelStyleHeights[CPHUDBezelStyle] = 20;
|
||||
}
|
||||
}
|
||||
|
||||
[self setKeyEquivalent:[cell keyEquivalent]];
|
||||
[self setKeyEquivalentModifierMask:[cell keyEquivalentModifierMask]];
|
||||
var self = [self NS_initWithCoder:aCoder];
|
||||
|
||||
return [self NS_initWithCoder:aCoder];
|
||||
[self setKeyEquivalent:[cell keyEquivalent]];
|
||||
_keyEquivalentModifierMask = [cell keyEquivalentModifierMask];
|
||||
|
||||
return self;
|
||||
}
|
||||
|
||||
- (Class)classForKeyedArchiver
|
||||
|
||||
Reference in new issue
Block a user