3 |
|
* |
4 |
|
* $Id$ |
5 |
|
* |
6 |
< |
* Basilisk II (C) 1997-2004 Christian Bauer |
6 |
> |
* Basilisk II (C) 1997-2008 Christian Bauer |
7 |
|
* |
8 |
|
* This program is free software; you can redistribute it and/or modify |
9 |
|
* it under the terms of the GNU General Public License as published by |
23 |
|
#import "Controller.h" |
24 |
|
#import "Emulator.h" |
25 |
|
|
26 |
– |
@implementation Controller |
27 |
– |
|
26 |
|
#import "sysdeps.h" // Types used in Basilisk C++ code |
27 |
|
|
28 |
|
#import <main.h> |
34 |
|
#import "misc_macosx.h" |
35 |
|
#import "video_macosx.h" |
36 |
|
|
37 |
+ |
@implementation Controller |
38 |
+ |
|
39 |
|
// |
40 |
|
// Standard NSApplication methods that we override |
41 |
|
// |
67 |
|
|
68 |
|
- (void) sendEvent: (NSEvent *)event; |
69 |
|
{ |
70 |
+ |
// We can either process the event ourselves, |
71 |
+ |
// or pass it to our superclass for the other UI objects to process |
72 |
+ |
bool passToSuper = false; |
73 |
+ |
|
74 |
|
if ( [self isAnyEmulatorDisplayingSheets] || |
75 |
|
[[thePrefsEditor window] isVisible] || ! [self isAnyEmulatorRunning] ) |
76 |
< |
[super sendEvent: event]; |
76 |
> |
passToSuper = true; |
77 |
> |
|
78 |
> |
if ( [[theEmulator screen] isFullScreen] ) |
79 |
> |
passToSuper = false; |
80 |
> |
|
81 |
> |
if ( passToSuper ) |
82 |
> |
[super sendEvent: event]; // NSApplication default |
83 |
|
else |
84 |
|
{ |
85 |
|
NSEventType type = [event type]; |