Add GameStream EOL link

This commit is contained in:
Cameron Gutman
2023-03-05 14:19:32 -06:00
parent 2c422c77fb
commit 83fd8225e4
5 changed files with 27 additions and 2 deletions
+4
View File
@@ -32,6 +32,10 @@ FOUNDATION_EXPORT NSString *const deviceName;
+ (unsigned short) addressPortStringToPort:(NSString*)addressPort;
+ (NSString*) addressAndPortToAddressPortString:(NSString*)address port:(unsigned short)port;
#if !TARGET_OS_TV
+ (void) launchUrl:(NSString*)urlString;
#endif
@end
@interface NSString (NSStringWithTrim)
+7 -1
View File
@@ -64,11 +64,17 @@ NSString *const deviceName = @"roth";
return NO;
}
#if !TARGET_OS_TV
+ (void) launchUrl:(NSString*)urlString {
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:urlString] options:@{} completionHandler:nil];
}
#endif
+ (void) addHelpOptionToDialog:(UIAlertController*)dialog {
#if !TARGET_OS_TV
// tvOS doesn't have a browser
[dialog addAction:[UIAlertAction actionWithTitle:@"Help" style:UIAlertActionStyleDefault handler:^(UIAlertAction* action){
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"https://github.com/moonlight-stream/moonlight-docs/wiki/Troubleshooting"]];
[Utils launchUrl:@"https://github.com/moonlight-stream/moonlight-docs/wiki/Troubleshooting"];
}]];
#endif
}