dpa99c / phonegap-launch-navigator

Phonegap/Cordova plugin which launches native route navigation apps for Android, iOS and Windows
369 stars 131 forks source link

Can this be used to override phone default settings? #257

Closed rolinger closed 3 years ago

rolinger commented 3 years ago

Hi Dave,

Just found this plugin. I read through the docs but couldn't get a sense of whether or not this plugin will solve the below problem.

My app is using other methods to open a map/route in chrome/safari or the maps app. It works fine, however, I am getting reports that for some users, when they click the link to open the map, it opens the Uber app. This is a phone setting where the users have accidentally set Uber as the default app to open maps/routes. Then those users think that my app is issue, that my app is broken or the source of the issue.

Can this plugin override that default setting...force a specific app (chrome/maps) or at a minimum always force the user to choose which app to use if its not chrome or maps app?

rolinger commented 3 years ago

upon further reading I am not certain this will meet my needs. This plugin routes to a specific location, however I am needing to pass a planned route that starts at point A and ends at point X - an example would be a bike route or a run route for a run club. It passes a link like this: https://goo.gl/maps/yA9GiVA1sra8oFeG8 - normally Chrome/Safari or Google Maps would open, but for some users they have accidentally set Uber as their default and this link won't open, nor route, within Uber. I was looking for a way to override the Uber default and set a new one or have the users pick which app to use everytime.

dpa99c commented 3 years ago

It's not possible to override default device settings. However you can use this plugin's appSelection API to present an in-app UI to prompt the user which installed navigation app to choose and then remember their choice next time.