Fixes #1558. Support "thick divider" split view style in nib2cib.

The thick divider style is converted to the pane splitter style in nib2cib since we only use two styles in Cappuccino.
This commit is contained in:
Alexander Ljungberg
2012-07-03 10:44:07 +01:00
parent fb590550cd
commit 37d4a06aa4
+6 -1
View File
@@ -22,6 +22,7 @@
@import <AppKit/CPSplitView.j>
var NSThinDividerStyle = 2;
@implementation CPSplitView (CPCoding)
@@ -30,7 +31,11 @@
if (self = [super NS_initWithCoder:aCoder])
{
_isVertical = [aCoder decodeBoolForKey:@"NSIsVertical"];
_isPaneSplitter = [aCoder decodeIntForKey:@"NSDividerStyle"] == 3;
// The possible values appear to be: no value (thick divider), 2 (thin divider) and 3 (pane splitter). For
// Cappuccino's purposes we treat thick divider and pane splitter as the same thing since the only difference
// seems to be graphical.
_isPaneSplitter = [aCoder decodeIntForKey:@"NSDividerStyle"] != NSThinDividerStyle;
_autosaveName = [aCoder decodeObjectForKey:@"NSAutosaveName"];
}