* GormCore/GormViewEditor.m

* GormCore/GormViewWindow.m: Minor correction to view resizing for
	windowless views to show contents properly.  Still working on
	editor issues.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/apps/gorm/trunk@26081 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Gregory John Casamento 2008-02-17 17:50:04 +00:00
parent a253bae6ee
commit 03ec2e7792
3 changed files with 29 additions and 8 deletions

View file

@ -1,3 +1,10 @@
2008-02-17 12:49-EST Gregory John Casamento <greg_casamento@yahoo.com>
* GormCore/GormViewEditor.m
* GormCore/GormViewWindow.m: Minor correction to view resizing for
windowless views to show contents properly. Still working on
editor issues.
2008-02-17 01:07-EST Gregory John Casamento <greg_casamento@yahoo.com>
* GormCore/GormInternalViewEditor.m

View file

@ -304,13 +304,11 @@ static BOOL currently_displaying = NO;
// if this window is nil when the editor is created, we know it's a
// standalone view.
/*
if([anObject window] == nil)
if([anObject window] == nil && [anObject superview] == nil)
{
NSDebugLog(@"#### Stand alone view: %@",_editedObject);
viewWindow = [[GormViewWindow alloc] initWithView: _editedObject];
}
*/
}
return self;

View file

@ -90,11 +90,14 @@
{
NSRect newFrame = [_view frame];
newFrame.origin.x = windowFrame.origin.x;
newFrame.origin.y = windowFrame.origin.y;
newFrame.size.height += 70;
newFrame.origin.x = windowFrame.origin.x+10;
newFrame.origin.y = windowFrame.origin.y+20;
newFrame.size.height += 100;
newFrame.size.width += 20;
[_view setPostsFrameChangedNotifications: NO];
[_view setFrame: newFrame];
[_view setPostsFrameChangedNotifications: YES];
[window setFrame: newFrame display: YES];
}
@ -122,6 +125,7 @@
else
{
[_view setFrame: newFrame];
[_view setNeedsDisplay: YES];
}
}
@ -169,8 +173,20 @@
- (void) activateEditorForView
{
id obj = [[(id<IB>)NSApp activeDocument] editorForObject: _view create: YES];
[obj activate];
id editor = [[(id<IB>)NSApp activeDocument] editorForObject: _view create: YES];
// NSArray *subviews = [_view subviews];
// NSEnumerator *en = [subviews objectEnumerator];
// id sub = nil;
// activate the parent and all subview editors...
[editor activate];
/*
while((sub = [en nextObject]) != nil)
{
editor = [[(id<IB>)NSApp activeDocument] editorForObject: sub create: YES];
[editor activate];
}
*/
}
- (void) encodeWithCoder: (NSCoder *)coder