Skip to content

Commit a49a786

Browse files
connorjclarkSiegeLord
authored andcommitted
osx: correctly restore cursor via cursorUpdate
1 parent 8218fab commit a49a786

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/macosx/osxgl.m

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -229,6 +229,7 @@ -(void) otherMouseDown: (NSEvent*) evt;
229229
-(void) otherMouseUp: (NSEvent*) evt;
230230
-(void) otherMouseDragged: (NSEvent*) evt;
231231
-(void) mouseMoved: (NSEvent*) evt;
232+
-(void) cursorUpdate: (NSEvent*) evt;
232233
-(void) scrollWheel: (NSEvent*) evt;
233234
-(void) viewDidMoveToWindow;
234235
-(void) viewWillMoveToWindow: (NSWindow*) newWindow;
@@ -413,6 +414,13 @@ -(void) mouseMoved: (NSEvent*) evt
413414
if (_osx_mouse_installed)
414415
_al_osx_mouse_generate_event(evt, dpy_ptr);
415416
}
417+
-(void) cursorUpdate: (NSEvent*) evt
418+
{
419+
if (_osx_mouse_installed) {
420+
ALLEGRO_DISPLAY_OSX_WIN* dpy = (ALLEGRO_DISPLAY_OSX_WIN*) dpy_ptr;
421+
_al_osx_change_cursor(dpy, dpy->cursor);
422+
}
423+
}
416424
-(void) scrollWheel: (NSEvent*) evt
417425
{
418426
if (_osx_mouse_installed)

0 commit comments

Comments
 (0)