[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Fix, nib2gmodel: GMAppKit.m
From: |
Georg Fleischmann |
Subject: |
Fix, nib2gmodel: GMAppKit.m |
Date: |
Fri, 19 Apr 2002 21:03:26 GMT |
Hi,
here is a little patch for nib2gmodel, which adds the NSTitledWindowMask to
the styleMask of windows which are not borderless.
The Interface Builder (at least on OpenStep) doesn't set NSTitledWindowMask,
even if other styles are included. I think that's a bug in OpenStep.
At least the window constrain stuff of GNUstep depends on this flag set.
Georg
2002-04-19 Georg Fleischmann
* gui/Model/GMAppKit.m
[NSWindow encodeWithModelArchiver:]:
add NSTitledWindowMask for non borderless windows.
*** gui/Model/GMAppKit.m.old Sat Mar 10 01:31:19 2001
--- gui/Model/GMAppKit.m Fri Apr 19 19:56:06 2002
***************
*** 1169,1174 ****
--- 1169,1175 ----
{
NSPoint wnOrigin = [self frame].origin;
NSRect ctFrame = [[self contentView] frame];
+ int style;
ctFrame.origin = wnOrigin;
***************
*** 1189,1195 ****
[archiver encodeBOOL:[self hidesOnDeactivate]
withName:@"hidesOnDeactivate"];
[archiver encodeObject:[self backgroundColor] withName:@"backgroundColor"];
! [archiver encodeUnsignedInt:[self styleMask] withName:@"styleMask"];
[archiver encodeUnsignedInt:[self backingType] withName:@"backingType"];
[archiver encodeConditionalObject:[self initialFirstResponder]
withName:@"initialFirstResponder"];
--- 1190,1199 ----
[archiver encodeBOOL:[self hidesOnDeactivate]
withName:@"hidesOnDeactivate"];
[archiver encodeObject:[self backgroundColor] withName:@"backgroundColor"];
! style = [self styleMask];
! if (style != NSBorderlessWindowMask)
! style |= NSTitledWindowMask;
! [archiver encodeUnsignedInt:style withName:@"styleMask"];
[archiver encodeUnsignedInt:[self backingType] withName:@"backingType"];
[archiver encodeConditionalObject:[self initialFirstResponder]
withName:@"initialFirstResponder"];
- Fix, nib2gmodel: GMAppKit.m,
Georg Fleischmann <=