You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by jc...@apache.org on 2021/06/11 12:25:53 UTC
[cordova-plugin-inappbrowser] branch master updated: fix(ios): make
system open tel, sms, mailto and geo links (#881)
This is an automated email from the ASF dual-hosted git repository.
jcesarmobile pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cordova-plugin-inappbrowser.git
The following commit(s) were added to refs/heads/master by this push:
new 2fef304 fix(ios): make system open tel, sms, mailto and geo links (#881)
2fef304 is described below
commit 2fef3046fcdbba301de637e200edba46d6f54052
Author: jcesarmobile <jc...@gmail.com>
AuthorDate: Fri Jun 11 14:25:43 2021 +0200
fix(ios): make system open tel, sms, mailto and geo links (#881)
---
src/ios/CDVWKInAppBrowser.m | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/ios/CDVWKInAppBrowser.m b/src/ios/CDVWKInAppBrowser.m
index cf4b6f6..2adcf0c 100644
--- a/src/ios/CDVWKInAppBrowser.m
+++ b/src/ios/CDVWKInAppBrowser.m
@@ -539,8 +539,9 @@ static CDVWKInAppBrowser* instance = nil;
[self.commandDelegate sendPluginResult:pluginResult callbackId:self.callbackId];
}
- //if is an app store link, let the system handle it, otherwise it fails to load it
- if ([[ url scheme] isEqualToString:@"itms-appss"] || [[ url scheme] isEqualToString:@"itms-apps"]) {
+ //if is an app store, tel, sms, mailto or geo link, let the system handle it, otherwise it fails to load it
+ NSArray * allowedSchemes = @[@"itms-appss", @"itms-apps", @"tel", @"sms", @"mailto", @"geo"];
+ if ([allowedSchemes containsObject:[url scheme]]) {
[theWebView stopLoading];
[self openInSystem:url];
shouldStart = NO;
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org