summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar lat9nq2021-07-15 21:02:38 -0400
committerGravatar lat9nq2021-07-16 15:43:12 -0400
commit0e6ba0cd0db6f338696ffba9180e15ea4a092323 (patch)
treed4d876998896eef6097969b1d7f118638bf7e889
parentemu_window_sdl2_vk: Use the generated SDL config (diff)
downloadyuzu-0e6ba0cd0db6f338696ffba9180e15ea4a092323.tar.gz
yuzu-0e6ba0cd0db6f338696ffba9180e15ea4a092323.tar.xz
yuzu-0e6ba0cd0db6f338696ffba9180e15ea4a092323.zip
emu_window_sdl2_vk: Specify the window manager if it should be supported
The original language "not implemented" is wrong if the implementation exists but is not compiled. This causes a bit of a debugging headache when it goes wrong. Log it if the window manager is known before exiting.
Diffstat (limited to '')
-rw-r--r--src/yuzu_cmd/emu_window/emu_window_sdl2_vk.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/yuzu_cmd/emu_window/emu_window_sdl2_vk.cpp b/src/yuzu_cmd/emu_window/emu_window_sdl2_vk.cpp
index b6049b032..7c870aea1 100644
--- a/src/yuzu_cmd/emu_window/emu_window_sdl2_vk.cpp
+++ b/src/yuzu_cmd/emu_window/emu_window_sdl2_vk.cpp
@@ -57,6 +57,11 @@ EmuWindow_SDL2_VK::EmuWindow_SDL2_VK(InputCommon::InputSubsystem* input_subsyste
57 window_info.type = Core::Frontend::WindowSystemType::Windows; 57 window_info.type = Core::Frontend::WindowSystemType::Windows;
58 window_info.render_surface = reinterpret_cast<void*>(wm.info.win.window); 58 window_info.render_surface = reinterpret_cast<void*>(wm.info.win.window);
59 break; 59 break;
60#else
61 case SDL_SYSWM_TYPE::SDL_SYSWM_WINDOWS:
62 LOG_CRITICAL(Frontend, "Window manager subsystem Windows not compiled");
63 std::exit(EXIT_FAILURE);
64 break;
60#endif 65#endif
61#ifdef SDL_VIDEO_DRIVER_X11 66#ifdef SDL_VIDEO_DRIVER_X11
62 case SDL_SYSWM_TYPE::SDL_SYSWM_X11: 67 case SDL_SYSWM_TYPE::SDL_SYSWM_X11:
@@ -64,6 +69,11 @@ EmuWindow_SDL2_VK::EmuWindow_SDL2_VK(InputCommon::InputSubsystem* input_subsyste
64 window_info.display_connection = wm.info.x11.display; 69 window_info.display_connection = wm.info.x11.display;
65 window_info.render_surface = reinterpret_cast<void*>(wm.info.x11.window); 70 window_info.render_surface = reinterpret_cast<void*>(wm.info.x11.window);
66 break; 71 break;
72#else
73 case SDL_SYSWM_TYPE::SDL_SYSWM_X11:
74 LOG_CRITICAL(Frontend, "Window manager subsystem X11 not compiled");
75 std::exit(EXIT_FAILURE);
76 break;
67#endif 77#endif
68#ifdef SDL_VIDEO_DRIVER_WAYLAND 78#ifdef SDL_VIDEO_DRIVER_WAYLAND
69 case SDL_SYSWM_TYPE::SDL_SYSWM_WAYLAND: 79 case SDL_SYSWM_TYPE::SDL_SYSWM_WAYLAND:
@@ -71,6 +81,11 @@ EmuWindow_SDL2_VK::EmuWindow_SDL2_VK(InputCommon::InputSubsystem* input_subsyste
71 window_info.display_connection = wm.info.wl.display; 81 window_info.display_connection = wm.info.wl.display;
72 window_info.render_surface = wm.info.wl.surface; 82 window_info.render_surface = wm.info.wl.surface;
73 break; 83 break;
84#else
85 case SDL_SYSWM_TYPE::SDL_SYSWM_WAYLAND:
86 LOG_CRITICAL(Frontend, "Window manager subsystem Wayland not compiled");
87 std::exit(EXIT_FAILURE);
88 break;
74#endif 89#endif
75 default: 90 default:
76 LOG_CRITICAL(Frontend, "Window manager subsystem not implemented"); 91 LOG_CRITICAL(Frontend, "Window manager subsystem not implemented");