ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/cebix/BasiliskII/src/MacOSX/Emulator.mm
(Generate patch)

Comparing BasiliskII/src/MacOSX/Emulator.mm (file contents):
Revision 1.4 by nigel, 2002-12-18T11:50:12Z vs.
Revision 1.5 by nigel, 2003-03-26T01:45:31Z

# Line 357 | Line 357 | uint8 lastXPRAM[XPRAM_SIZE];           // Copy of
357  
358   - (void) emulThread
359   {
360        extern uint8            *RAMBaseHost, *ROMBaseHost;
360          NSAutoreleasePool       *pool = [NSAutoreleasePool new];
361  
362 <        InitEmulator();
362 >        if ( ! InitEmulator() )
363 >        {
364 >                [redraw suspend];               // Stop the barberpole
365  
366 <        if ( RAMBaseHost == NULL || ROMBaseHost == NULL )
367 <                ErrorSheet(@"Cannot start Emulator",
367 <                                   @"Emulator memory not allocated", nil, win);
366 >                ErrorSheet(@"Cannot start Emulator", @"", @"Quit", win);
367 >        }
368          else
369          {
370                  memcpy(lastXPRAM, XPRAM, XPRAM_SIZE);
# Line 374 | Line 374 | uint8 lastXPRAM[XPRAM_SIZE];           // Copy of
374                  while ( screen == nil ) // If we are still loading from Nib?
375                          [NSThread sleepUntilDate:[NSDate dateWithTimeIntervalSinceNow: 1.0]];
376  
377 < //              [screen readyToDraw];
378 <                [self   runUpdate];
377 >                [self   runUpdate];             // Set the window close gadget to dimpled
378  
379                  Start680x0();                   // Start 68k and jump to ROM boot routine
380  
381                  puts ("Emulator exited normally");
382          }
383  
385        running = NO;
386        uaeCreated = NO;
387        [self runUpdate];                       // Update button & dimple
384          [pool release];
385 <        [self exitThreads];
385 >        QuitEmulator();
386   }
387  
388   - (void) RTCinterrupt

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines