Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/exultmenu.cc b/exultmenu.cc
- index d9e2292c..633a1d2d 100644
- --- a/exultmenu.cc
- +++ b/exultmenu.cc
- @@ -394,7 +394,11 @@ BaseGameInfo *ExultMenu::run() {
- throw quit_exception(1);
- #else
- // Never quits because Apple doesn't allow you to.
- +#if SDL_VERSION_ATLEAST(2,0,13)
- + SDL_OpenURL("http://exult.sourceforge.net/docs.php#ios_games");
- +#else
- ios_open_url("http://exult.sourceforge.net/docs.php#ios_games");
- +#endif
- while (1) {
- wait_delay(1000);
- }
- @@ -486,7 +490,11 @@ BaseGameInfo *ExultMenu::run() {
- break;
- case -1: // Exit
- #ifdef __IPHONEOS__
- +#if SDL_VERSION_ATLEAST(2,0,13)
- + SDL_OpenURL("http://exult.sourceforge.net/docs.php#iOS%20Guide");
- +#else
- ios_open_url("http://exult.sourceforge.net/docs.php#iOS%20Guide");
- +#endif
- break;
- #else
- gpal->fade_out(c_fade_out_time);
- diff --git a/ios/ios_utils.mm b/ios/ios_utils.mm
- index f6e7457d..3bc87141 100644
- --- a/ios/ios_utils.mm
- +++ b/ios/ios_utils.mm
- @@ -257,8 +257,11 @@ const char* ios_get_documents_dir()
- return docs_dir;
- }
- +/* not needed for SDL 2.0.13 because of SDL_OpenURL()*/
- +#if !SDL_VERSION_ATLEAST(2,0,13)
- void ios_open_url(const char *sUrl)
- {
- NSURL *url = [NSURL URLWithString:[NSString stringWithUTF8String:sUrl]];
- [[UIApplication sharedApplication] openURL:url options:@{} completionHandler:nil];
- }
- +#endif
Add Comment
Please, Sign In to add comment