Fixes for NSScrollView

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@4842 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 1999-09-07 05:31:44 +00:00
parent 63e43e1956
commit 44dc7234b5
3 changed files with 101 additions and 15 deletions

View file

@ -425,28 +425,40 @@ void __dummy_GMAppKit_functionForLinking() {}
return [NSArray array];
}
- (void)encodeWithModelArchiver:(GMArchiver*)archiver
- (void) encodeWithModelArchiver: (GMArchiver*)archiver
{
[super encodeWithModelArchiver:archiver];
[super encodeWithModelArchiver: archiver];
[archiver encodeObject:[self backgroundColor] withName:@"backgroundColor"];
[archiver encodeInt:[self borderType] withName:@"borderType"];
[archiver encodeBOOL:[self hasHorizontalScroller] withName:@"hasHorizontalScroller"];
[archiver encodeBOOL:[self hasVerticalScroller] withName:@"hasVerticalScroller"];
[archiver encodeObject:[self documentView] withName:@"documentView"];
[archiver encodeObject: [self backgroundColor]
withName: @"backgroundColor"];
[archiver encodeInt: [self borderType]
withName: @"borderType"];
[archiver encodeBOOL: [self hasHorizontalScroller]
withName: @"hasHorizontalScroller"];
[archiver encodeBOOL: [self hasVerticalScroller]
withName: @"hasVerticalScroller"];
[archiver encodeObject: [self documentView]
withName: @"documentView"];
}
- (id)initWithModelUnarchiver:(GMUnarchiver*)unarchiver
- (id) initWithModelUnarchiver: (GMUnarchiver*)unarchiver
{
self = [super initWithModelUnarchiver:unarchiver];
self = [super initWithModelUnarchiver: unarchiver];
[self setBackgroundColor:[unarchiver decodeObjectWithName:@"backgroundColor"]];
[self setBorderType:[unarchiver decodeIntWithName:@"borderType"]];
[self setHasHorizontalScroller:[unarchiver decodeBOOLWithName:@"hasHorizontalScroller"]];
[self setHasVerticalScroller:[unarchiver decodeBOOLWithName:@"hasVerticalScroller"]];
[self setDocumentView:[unarchiver decodeObjectWithName:@"documentView"]];
[self setContentView: AUTORELEASE([NSClipView new])];
return self;
[self setBackgroundColor:
[unarchiver decodeObjectWithName: @"backgroundColor"]];
[self setBorderType:
[unarchiver decodeIntWithName: @"borderType"]];
[self setHasHorizontalScroller:
[unarchiver decodeBOOLWithName: @"hasHorizontalScroller"]];
[self setHasVerticalScroller:
[unarchiver decodeBOOLWithName: @"hasVerticalScroller"]];
[self setDocumentView:
[unarchiver decodeObjectWithName: @"documentView"]];
return self;
}
@end /* NSScrollView (GMArchiverMethods) */