|
@@ -116,6 +116,7 @@
|
|
|
#define SDL_HAS_CAPTURE_AND_GLOBAL_MOUSE 0
|
|
|
#endif
|
|
|
#define SDL_HAS_VULKAN SDL_VERSION_ATLEAST(2,0,6)
|
|
|
+#define SDL_HAS_OPEN_URL SDL_VERSION_ATLEAST(2,0,14)
|
|
|
#if SDL_HAS_VULKAN
|
|
|
#include <SDL_vulkan.h>
|
|
|
#endif
|
|
@@ -481,7 +482,7 @@ static bool ImGui_ImplSDL2_Init(SDL_Window* window, SDL_Renderer* renderer, void
|
|
|
platform_io.Platform_SetImeDataFn = ImGui_ImplSDL2_PlatformSetImeData;
|
|
|
#ifdef __EMSCRIPTEN__
|
|
|
platform_io.Platform_OpenInShellFn = [](ImGuiContext*, const char* url) { ImGui_ImplSDL2_EmscriptenOpenURL(url); return true; };
|
|
|
-#else
|
|
|
+#elif SDL_HAS_OPEN_URL
|
|
|
platform_io.Platform_OpenInShellFn = [](ImGuiContext*, const char* url) { return SDL_OpenURL(url) == 0; };
|
|
|
#endif
|
|
|
|