mirror of
https://github.com/encounter/SDL.git
synced 2025-12-11 06:27:44 +00:00
Removed SDL_AndroidOpenURL, added SDL_OpenURL.
Still needs to be wired into Xcode and Visual Studio projects.
This commit is contained in:
@@ -37,6 +37,8 @@ extern "C" {
|
||||
#include "SDL_bframebuffer.h"
|
||||
#include "SDL_bevents.h"
|
||||
|
||||
#include <Url.h>
|
||||
|
||||
/* FIXME: Undefined functions */
|
||||
// #define HAIKU_PumpEvents NULL
|
||||
#define HAIKU_StartTextInput NULL
|
||||
@@ -193,6 +195,15 @@ void HAIKU_VideoQuit(_THIS)
|
||||
SDL_QuitBeApp();
|
||||
}
|
||||
|
||||
// just sticking this function in here so it's in a C++ source file.
|
||||
extern "C" { int HAIKU_OpenURL(const char *url); }
|
||||
int HAIKU_OpenURL(const char *url)
|
||||
{
|
||||
BUrl burl(url);
|
||||
const status_t rc = burl.OpenWithPreferredApplication(false);
|
||||
return (rc == B_NO_ERROR) ? 0 : SDL_SetError("URL open failed (err=%d)", (int) rc);
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user