Add intent scheme to be handled by OS
The intent scheme `intent://` is [recommended by Google ](https://developer.chrome.com/multidevice/android/intents) for launching apps. Cordova should forward this to the OS to handle appropriately. This closes #183
This commit is contained in:
parent
57b50b1d65
commit
cc2ec22695
@ -843,7 +843,7 @@ public class InAppBrowser extends CordovaPlugin {
|
|||||||
} catch (android.content.ActivityNotFoundException e) {
|
} catch (android.content.ActivityNotFoundException e) {
|
||||||
LOG.e(LOG_TAG, "Error dialing " + url + ": " + e.toString());
|
LOG.e(LOG_TAG, "Error dialing " + url + ": " + e.toString());
|
||||||
}
|
}
|
||||||
} else if (url.startsWith("geo:") || url.startsWith(WebView.SCHEME_MAILTO) || url.startsWith("market:")) {
|
} else if (url.startsWith("geo:") || url.startsWith(WebView.SCHEME_MAILTO) || url.startsWith("market:") || url.startsWith("intent:")) {
|
||||||
try {
|
try {
|
||||||
Intent intent = new Intent(Intent.ACTION_VIEW);
|
Intent intent = new Intent(Intent.ACTION_VIEW);
|
||||||
intent.setData(Uri.parse(url));
|
intent.setData(Uri.parse(url));
|
||||||
|
Loading…
Reference in New Issue
Block a user