SDL/src/video/cocoa
Cameron Gutman 3046d55d0e cocoa: Return an error if GetWindowDisplayIndex() is called too early
SDL_CreateWindow() may call GetWindowDisplayIndex() to compute the position
of a new window that the caller has requested to be placed on a certain
display. Since we haven't fully constructed the window yet, our driverdata
will be nil and we will fail to get the NSScreen (which is fine). However,
we need to return an error (not 0, which is a valid display index) for
SDL_GetWindowDisplayIndex() to know to figure out the display index itself.

Fixes positioning new windows on secondary displays when using
SDL_WINDOWPOS_CENTERED_DISPLAY() and SDL_WINDOWPOS_UNDEFINED_DISPLAY().
2022-08-12 20:30:59 -07:00
..
SDL_cocoaclipboard.h macOS: always use Objective-C ARC (automatic ref counting). 2022-05-09 21:53:40 -07:00
SDL_cocoaclipboard.m macOS: always use Objective-C ARC (automatic ref counting). 2022-05-09 21:53:40 -07:00
SDL_cocoaevents.h Updated copyright for 2022 2022-01-03 09:40:21 -08:00
SDL_cocoaevents.m Fix Main Thread Checker warning on macOS 2022-07-26 15:17:44 -04:00
SDL_cocoakeyboard.h make SDL_SetTextInputRect take a pointer to const 2022-07-04 09:38:01 -07:00
SDL_cocoakeyboard.m keyboard: Only send SDL_KEYMAPCHANGED when the keymap actually changes 2022-07-31 14:02:28 -07:00
SDL_cocoamessagebox.h Updated copyright for 2022 2022-01-03 09:40:21 -08:00
SDL_cocoamessagebox.m Fix C89 declaration for macOS modules. 2022-06-27 15:19:40 -07:00
SDL_cocoametalview.h Leave the Metal view active on the window when recreating the Metal renderer 2022-01-07 12:38:45 -08:00
SDL_cocoametalview.m macOS: remove dead code for supporting 10.6 at runtime. 2022-05-10 14:04:14 -07:00
SDL_cocoamodes.h Updated copyright for 2022 2022-01-03 09:40:21 -08:00
SDL_cocoamodes.m Fix C89 declaration for macOS modules. 2022-06-27 15:19:40 -07:00
SDL_cocoamouse.h Updated copyright for 2022 2022-01-03 09:40:21 -08:00
SDL_cocoamouse.m cocoa: Don't crash if moving a message box created before SDL_Init. 2022-07-26 14:45:26 -04:00
SDL_cocoaopengl.h Updated copyright for 2022 2022-01-03 09:40:21 -08:00
SDL_cocoaopengl.m cocoa: Change the new sync_dispatch hint to async_dispatch. 2022-08-10 10:48:23 -04:00
SDL_cocoaopengles.h Updated copyright for 2022 2022-01-03 09:40:21 -08:00
SDL_cocoaopengles.m Fix C89 declaration for macOS modules. 2022-06-27 15:19:40 -07:00
SDL_cocoashape.h Updated copyright for 2022 2022-01-03 09:40:21 -08:00
SDL_cocoashape.m Fix C89 declaration for macOS modules. 2022-06-27 15:19:40 -07:00
SDL_cocoavideo.h cocoa: Added hint to treat MacBook trackpads as touch devices, not mice. 2022-08-10 00:42:31 -04:00
SDL_cocoavideo.m cocoa: Added hint to treat MacBook trackpads as touch devices, not mice. 2022-08-10 00:42:31 -04:00
SDL_cocoavulkan.h Updated copyright for 2022 2022-01-03 09:40:21 -08:00
SDL_cocoavulkan.m Updated copyright for 2022 2022-01-03 09:40:21 -08:00
SDL_cocoawindow.h cocoa: Added hint to treat MacBook trackpads as touch devices, not mice. 2022-08-10 00:42:31 -04:00
SDL_cocoawindow.m cocoa: Return an error if GetWindowDisplayIndex() is called too early 2022-08-12 20:30:59 -07:00