mirror of
https://github.com/samuelclay/NewsBlur.git
synced 2025-09-18 21:50:56 +00:00
Add Edge as a browser option
This commit is contained in:
parent
9e6e82b333
commit
3f10bf866e
3 changed files with 15 additions and 0 deletions
|
@ -2070,6 +2070,17 @@
|
|||
NSString *encodedURL = [url.absoluteString stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLHostAllowedCharacterSet]];
|
||||
NSString *firefoxURL = [NSString stringWithFormat:@"%@%@", @"firefox://open-url?url=", encodedURL];
|
||||
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:firefoxURL] options:@{} completionHandler:nil];
|
||||
} else if ([storyBrowser isEqualToString:@"edge"]){
|
||||
NSString *edgeURL;
|
||||
NSRange prefix = [[url absoluteString] rangeOfString: @"http"];
|
||||
|
||||
if (NSNotFound != prefix.location) {
|
||||
edgeURL = [[url absoluteString]
|
||||
stringByReplacingCharactersInRange: prefix
|
||||
withString: @"microsoft-edge-http"];
|
||||
}
|
||||
|
||||
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:edgeURL] options:@{} completionHandler:nil];
|
||||
} else if ([storyBrowser isEqualToString:@"inappsafari"]) {
|
||||
[self showSafariViewControllerWithURL:url useReader:NO];
|
||||
} else if ([storyBrowser isEqualToString:@"inappsafarireader"]) {
|
||||
|
|
|
@ -726,6 +726,7 @@
|
|||
<string>Chrome</string>
|
||||
<string>Opera Mini</string>
|
||||
<string>Firefox</string>
|
||||
<string>Edge</string>
|
||||
</array>
|
||||
<key>DefaultValue</key>
|
||||
<string>inappsafari</string>
|
||||
|
@ -738,6 +739,7 @@
|
|||
<string>chrome</string>
|
||||
<string>opera_mini</string>
|
||||
<string>firefox</string>
|
||||
<string>edge</string>
|
||||
</array>
|
||||
<key>Key</key>
|
||||
<string>story_browser</string>
|
||||
|
|
|
@ -746,6 +746,7 @@
|
|||
<string>Chrome</string>
|
||||
<string>Opera Mini</string>
|
||||
<string>Firefox</string>
|
||||
<string>Edge</string>
|
||||
</array>
|
||||
<key>DefaultValue</key>
|
||||
<string>inappsafari</string>
|
||||
|
@ -758,6 +759,7 @@
|
|||
<string>chrome</string>
|
||||
<string>opera_mini</string>
|
||||
<string>firefox</string>
|
||||
<string>edge</string>
|
||||
</array>
|
||||
<key>Key</key>
|
||||
<string>story_browser</string>
|
||||
|
|
Loading…
Add table
Reference in a new issue