Update of /cvsroot/scopeapp/scopeapp/src
In directory usw-pr-cvs1:/tmp/cvs-serv7131/src
Modified Files:
main.m
Log Message:
Manually create delegate object and load MainMenu.nib
Index: main.m
===================================================================
RCS file: /cvsroot/scopeapp/scopeapp/src/main.m,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** main.m 21 Jul 2002 19:38:08 -0000 1.2
--- main.m 22 Jul 2002 09:15:44 -0000 1.3
***************
*** 1,2 ****
--- 1,27 ----
+ //
+ // main.m
+ // MacCRO X
+ //
+ // Copyright (c) 2002 Philip Derrin and Rafal Kolanski.
+ //
+ // This file is part of MacCRO X.
+ //
+ // MacCRO X is free software; you can redistribute it and/or modify
+ // it under the terms of the GNU General Public License as published by
+ // the Free Software Foundation; either version 2 of the License, or
+ // (at your option) any later version.
+ //
+ // MacCRO X is distributed in the hope that it will be useful,
+ // but WITHOUT ANY WARRANTY; without even the implied warranty of
+ // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ // GNU General Public License for more details.
+ //
+ // You should have received a copy of the GNU General Public License
+ // along with MacCRO X; if not, write to the Free Software
+ // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ //
+ // $Header$
+ //
+
#import <AppKit/AppKit.h>
#import "ScopeAppDelegate.h"
***************
*** 4,12 ****
int main(int argc, const char *argv[])
{
! // attempting to intuitively use ScopeAppDelegate as the delegate
! // for the whole application FIXME
[NSApplication sharedApplication];
[NSApp setDelegate: [ScopeAppDelegate new]];
!
! return NSApplicationMain(argc, argv);
}
--- 29,42 ----
int main(int argc, const char *argv[])
{
! NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
!
[NSApplication sharedApplication];
+
[NSApp setDelegate: [ScopeAppDelegate new]];
! [NSBundle loadNibNamed:@"MainMenu" owner: NSApp];
! [NSApp run];
!
! [pool release];
!
! return 0;
}
|