Add support for modal windows to more platforms

- Adds support for modal windows to Win32, Mac, and Haiku, and enhances functionality on Wayland and X11, which previous set only the parent window, but not the modal state.
- Windows can be declared modal at creation time, and the modal state can be toggled at any time via SDL_SetWindowModalFor() (tested with UE5 through sdl2-compat).
- Allows dynamic unparenting/reparenting of windows.
- Includes a modal window test.
This commit is contained in:
Semphris authored and Frank Praznik committed 2024-04-30 13:47:57 -04:00
1 parent 97f7b4620a
commit c6a70d6898
20 files changed
+592 -51

No files matched your search

+1
View File
@@ -414,6 +414,7 @@ add_sdl_test_executable(testpopup SOURCES testpopup.c)
add_sdl_test_executable(testdialog SOURCES testdialog.c)
add_sdl_test_executable(testtime SOURCES testtime.c)
add_sdl_test_executable(testmanymouse SOURCES testmanymouse.c)
add_sdl_test_executable(testmodal SOURCES testmodal.c)
if (HAVE_WAYLAND)
# Set the GENERATED property on the protocol file, since it is first created at build time