mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-08-01 16:06:59 +00:00
Add Microsoft Edge open-in option
This commit is contained in:
parent
a69bd5f9d8
commit
26d63cf258
@ -258,6 +258,8 @@
|
||||
<string>moovit</string>
|
||||
<string>alook</string>
|
||||
<string>dgis</string>
|
||||
<string>microsoft-edge-http</string>
|
||||
<string>microsoft-edge-https</string>
|
||||
</array>
|
||||
<key>LSRequiresIPhoneOS</key>
|
||||
<true/>
|
||||
|
@ -116,6 +116,16 @@ private func allOpenInOptions(context: AccountContext, item: OpenInItem) -> [Ope
|
||||
}
|
||||
return .none
|
||||
}))
|
||||
|
||||
options.append(OpenInOption(identifier: "edge", application: .other(title: "Microsoft Edge", identifier: 1288723196, scheme: "microsoft-edge-http", store: nil), action: {
|
||||
if let url = URL(string: url), var components = URLComponents(url: url, resolvingAgainstBaseURL: true) {
|
||||
components.scheme = components.scheme == "https" ? "microsoft-edge-https" : "microsoft-edge-http"
|
||||
if let url = components.string {
|
||||
return .openUrl(url: url)
|
||||
}
|
||||
}
|
||||
return .none
|
||||
}))
|
||||
|
||||
options.append(OpenInOption(identifier: "duckDuckGo", application: .other(title: "DuckDuckGo", identifier: 663592361, scheme: "ddgQuickLink", store: nil), action: {
|
||||
return .openUrl(url: "ddgQuickLink://\(url)")
|
||||
|
Loading…
x
Reference in New Issue
Block a user