diff src/video/quartz/SDL_QuartzEvents.m @ 168:e92aa316c517

Added Max's patches for building MacOS X apps on command line
author Sam Lantinga <slouken@libsdl.org>
date Tue, 04 Sep 2001 23:18:45 +0000
parents 4382c38dfbee
children 37e3ca9254c7
line wrap: on
line diff
--- a/src/video/quartz/SDL_QuartzEvents.m	Tue Sep 04 22:53:46 2001 +0000
+++ b/src/video/quartz/SDL_QuartzEvents.m	Tue Sep 04 23:18:45 2001 +0000
@@ -206,6 +206,12 @@
         QZ_WarpWMCursor (this, SDL_VideoSurface->w / 2, SDL_VideoSurface->h / 2);
         CGAssociateMouseAndMouseCursorPosition (0);
     }
+
+    /* Hide the mouse cursor if inside the app window */
+    // FIXME
+    if (!QZ_cursor_visible) {
+            HideCursor ();
+    }
     
     SDL_PrivateAppActive (1, SDL_APPINPUTFOCUS);
 }
@@ -218,6 +224,12 @@
     if (currentGrabMode == SDL_GRAB_ON) {
         CGAssociateMouseAndMouseCursorPosition (1);
     }
+
+    /* Show the mouse cursor */
+    // FIXME
+    if (!QZ_cursor_visible) {
+            ShowCursor ();
+    }
     
     SDL_PrivateAppActive (0, SDL_APPINPUTFOCUS);
 }
@@ -309,6 +321,8 @@
             case NSRightMouseDragged:
             case 27:
             case NSMouseMoved:
+                if ( (SDL_VideoSurface->flags & SDL_FULLSCREEN)
+                	|| NSPointInRect([event locationInWindow], winRect) )
                 {
                    static int moves = 0;
                    NSPoint p;