From 22ad6f6931e51738146c0e01b169d0c65bee312d Mon Sep 17 00:00:00 2001 From: dynaflash Date: Tue, 27 Jan 2009 17:47:35 +0000 Subject: MacGui: remember window postion and open/close state of the Picture Filter and Picture sizing inspectors and restore them at the next launch. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@2101 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- macosx/PictureController.mm | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'macosx/PictureController.mm') diff --git a/macosx/PictureController.mm b/macosx/PictureController.mm index 1ffb3ae48..4965f76f8 100644 --- a/macosx/PictureController.mm +++ b/macosx/PictureController.mm @@ -44,6 +44,7 @@ else { [self showWindow:sender]; + [[NSUserDefaults standardUserDefaults] setBool:YES forKey:@"PictureSizeWindowIsOpen"]; if ([fPreviewController fullScreen] == YES) { [self setToFullScreenMode]; @@ -92,12 +93,16 @@ - (void)awakeFromNib { [fPictureWindow setDelegate:self]; + if( ![[self window] setFrameUsingName:@"PictureSizing"] ) + [[self window] center]; + [self setWindowFrameAutosaveName:@"PictureSizing"]; + [[self window] setExcludedFromWindowsMenu:YES]; } - (void)windowWillClose:(NSNotification *)aNotification { - +[[NSUserDefaults standardUserDefaults] setBool:NO forKey:@"PictureSizeWindowIsOpen"]; } - (BOOL)windowShouldClose:(id)fPictureWindow -- cgit v1.2.3