From 586a81c7d6e02ceb5cab10e5356a8a1ff3253eda Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jaakko=20Ker=C3=A4nen?= jaakko.keranen@iki.fi
Date: Tue, 22 Dec 2020 08:40:39 +0200
Subject: [PATCH 1/1] App: Attempt to open URLs using SDL first
SDL_OpenURL() was added in 2.0.14.
src/app.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/src/app.c b/src/app.c
index 4ea37cd4..e1b981d8 100644
--- a/src/app.c
+++ b/src/app.c
@@ -54,6 +54,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */
#include <SDL_render.h>
#include <SDL_timer.h>
#include <SDL_video.h>
+#include <SDL_misc.h>
+#include <SDL_version.h>
#include <stdio.h>
#include <stdarg.h>
@@ -1437,6 +1439,11 @@ iBool handleCommand_App(const char *cmd) {
}
void openInDefaultBrowser_App(const iString *url) {
+#if SDL_VERSION_ATLEAST(2, 0, 14)
return;
+#endif
iProcess *proc = new_Process();
setArguments_Process(proc,
#if defined (iPlatformApple)
--
2.25.1
text/plain
This content has been proxied by September (ba2dc).