2
2
* Controller.m - Simple application window management.
4
* $Id: Controller.mm,v 1.9 2003/04/01 01:56:41 nigel Exp $
4
* $Id: Controller.mm,v 1.12 2005/01/30 21:42:13 gbeauche Exp $
6
* Basilisk II (C) 1997-2001 Christian Bauer
6
* Basilisk II (C) 1997-2005 Christian Bauer
8
8
* This program is free software; you can redistribute it and/or modify
9
9
* it under the terms of the GNU General Public License as published by
109
109
// switch ( NSRunAlertPanel(title, msg, def, alt, other, nil) )
111
// case NSAlertDefault: savePrefs();
112
// case NSAlertAlternate: return NSTerminateNow;
113
// case NSAlertOther: return NSTerminateCancel;
111
// case NSAlertDefault: savePrefs();
112
// case NSAlertAlternate: return NSTerminateNow;
113
// case NSAlertOther: return NSTerminateCancel;
262
262
- (IBAction) HelpHowTo: (id)sender
264
NSString *path = [[NSBundle mainBundle] pathForResource: @"HowTo"
264
NSString *path = [[NSBundle mainBundle] pathForResource: @"HowTo"
268
InfoSheet(@"Cannot find HowTo.html", [theEmulator window]);
270
if ( ! [[NSWorkspace sharedWorkspace] openFile: path
271
withApplication: @"TextEdit"] )
272
InfoSheet(@"Cannot open HowTo.html with TextEdit", [theEmulator window]);
268
InfoSheet(@"Cannot find HowTo.html", [theEmulator window]);
270
if ( ! [[NSWorkspace sharedWorkspace] openFile: path] )
271
InfoSheet(@"Cannot open HowTo.html with default app", [theEmulator window]);
275
274
- (IBAction) HelpToDo: (id)sender
277
NSString *path = [[NSBundle mainBundle] pathForResource: @"ToDo"
276
NSString *path = [[NSBundle mainBundle] pathForResource: @"ToDo"
281
InfoSheet(@"Cannot find ToDo.html", [theEmulator window]);
283
if ( ! [[NSWorkspace sharedWorkspace] openFile: path
284
withApplication: @"TextEdit"] )
285
InfoSheet(@"Cannot open ToDo.html with TextEdit", [theEmulator window]);
280
InfoSheet(@"Cannot find ToDo.html", [theEmulator window]);
282
if ( ! [[NSWorkspace sharedWorkspace] openFile: path
283
withApplication: @"TextEdit"] )
284
InfoSheet(@"Cannot open ToDo.html with TextEdit", [theEmulator window]);
288
287
- (IBAction) HelpVersions: (id)sender
290
NSString *path = [[NSBundle mainBundle] pathForResource: @"Versions"
289
NSString *path = [[NSBundle mainBundle] pathForResource: @"Versions"
294
InfoSheet(@"Cannot find Versions.html", [theEmulator window]);
296
if ( ! [[NSWorkspace sharedWorkspace] openFile: path
297
withApplication: @"TextEdit"] )
298
InfoSheet(@"Cannot open Versions.html with TextEdit",
293
InfoSheet(@"Cannot find Versions.html", [theEmulator window]);
295
if ( ! [[NSWorkspace sharedWorkspace] openFile: path
296
withApplication: @"TextEdit"] )
297
InfoSheet(@"Cannot open Versions.html with TextEdit",
299
298
[theEmulator window]);