formatting and now subclassing is tested by Open a document

This commit is contained in:
ggsato
2012-05-26 11:08:57 +09:00
parent 310422adb1
commit fabe1d8991
5 changed files with 17 additions and 10 deletions
@@ -12,20 +12,17 @@
@implementation AppController : CPObject
{
CPDocumentController subclassedCPDocumentController;
}
- (void)applicationDidFinishLaunching:(CPNotification)aNotification
{
// This is called when the application is done loading.
var cpAlert = [CPAlert alertWithMessageText:@"Is this the shared instance? " + ([CPDocumentController sharedDocumentController] == subclassedCPDocumentController) defaultButton:@"OK" alternateButton:nil otherButton:nil informativeTextWithFormat:nil];
[cpAlert beginSheetModalForWindow:[[CPApplication sharedApplication] mainWindow]];
}
- (void)applicationWillFinishLaunching:(CPNotification)aNotification
{
// instantiate a subclass of DocumentController
subclassedCPDocumentController = [[DocumentController alloc] init];
[[DocumentController alloc] init];
}
- (void)awakeFromCib