151 |
|
|
152 |
|
- (IBAction) Interrupt: (id)sender; |
153 |
|
{ |
154 |
< |
WarningSheet (@"Interrupt action not yet supported", @"", @"OK", win); |
154 |
> |
WarningSheet (@"Interrupt action not yet supported", win); |
155 |
|
} |
156 |
|
|
157 |
|
- (IBAction) PowerKey: (id)sender; |
204 |
|
[xPRAM resume]; |
205 |
|
} |
206 |
|
|
207 |
+ |
- (IBAction) ScreenHideShow: (NSButton *)sender; |
208 |
+ |
{ |
209 |
+ |
WarningSheet(@"Nigel doesn't know how to shrink or grow this window", |
210 |
+ |
@"Maybe you can grab the source code and have a go yourself?", |
211 |
+ |
nil, win); |
212 |
+ |
} |
213 |
+ |
|
214 |
|
- (IBAction) Snapshot: (id) sender |
215 |
|
{ |
216 |
|
if ( screen == nil || uaeCreated == NO ) |
217 |
|
WarningSheet(@"The emulator has not yet started.", |
218 |
|
@"There is no screen output to snapshot", |
219 |
< |
@"OK", win); |
219 |
> |
nil, win); |
220 |
|
else |
221 |
|
{ |
222 |
|
NSData *TIFFdata; |
310 |
|
- (void) createThreads |
311 |
|
{ |
312 |
|
#ifdef USE_PTHREADS |
313 |
< |
[NSThread detachNewThreadSelector:(SEL)"" toTarget:nil withObject:nil]; // Make UI threadsafe |
313 |
> |
// Make UI threadsafe: |
314 |
> |
[NSThread detachNewThreadSelector:(SEL)"" toTarget:nil withObject:nil]; |
315 |
|
//emul = [[NNThread alloc] initWithAutoReleasePool]; |
316 |
|
#endif |
317 |
|
emul = [[NNThread alloc] init]; |
362 |
|
extern uint8 *RAMBaseHost, *ROMBaseHost; |
363 |
|
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; |
364 |
|
|
357 |
– |
// [screen allocBitmap]; // Do this first, because InitEmulator() calls VideoInit(), which needs the_bitmap. |
358 |
– |
|
365 |
|
InitEmulator(); |
366 |
|
|
367 |
|
if ( RAMBaseHost == NULL || ROMBaseHost == NULL ) |
368 |
< |
ErrorSheet(@"Cannot start Emulator.", |
369 |
< |
@"Emulator memory not allocated", @"OK", win); |
368 |
> |
ErrorSheet(@"Cannot start Emulator", |
369 |
> |
@"Emulator memory not allocated", nil, win); |
370 |
|
else |
371 |
|
{ |
372 |
|
memcpy(lastXPRAM, XPRAM, XPRAM_SIZE); |
373 |
|
|
374 |
|
uaeCreated = YES; // Enable timers to access emulated Mac's memory |
375 |
|
|
376 |
< |
while ( screen == nil ) // If init sets running, but we are still loading from Nib? |
376 |
> |
while ( screen == nil ) // If we are still loading from Nib? |
377 |
|
[NSThread sleepUntilDate:[NSDate dateWithTimeIntervalSinceNow: 1.0]]; |
378 |
|
|
379 |
|
// [screen readyToDraw]; |
433 |
|
} |
434 |
|
} |
435 |
|
|
436 |
< |
@end |
436 |
> |
@end |