dpa99c / phonegap-launch-navigator

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

Default app can't be reset #196

Closed Holbanner closed 6 years ago

Holbanner commented 6 years ago

I'm submitting a ... (check one with "x"):

Bug report

Current behavior:

When selecting to remember the choice of default app, it is not possible to reset that choice from android parameters afterward.

I've tried opening navigation apps from other apps. When prompted to select the navigation app I choose one then selected to remember my choice. After that I could reset that choice by going paramters->applications->{waze/maps/uber/...}->defaults-->remove defaults. Then when relaunching Navigation from another app i was prompted again with the choice. When doing this after choosing to remember with the plugin there is no defaults in the navigation app Expected behavior:

Once the default navigation app is remembered it should be resetable through parameters Steps to reproduce:

On any project using launch navigator, start a navigation, select an app, select remember your choice and try to reset that choice so you can reselect it later. Environment information

Runtime issue

If using an [Ionic Native Typescript wrapper]() for this plugin:

global packages:

cordova (Cordova CLI) : 8.0.0

local packages:

@ionic/app-scripts : 3.1.9
Cordova Platforms  : android 6.3.0 ios 4.5.4
Ionic Framework    : ionic-angular 3.9.0

System:

ios-deploy : 1.9.2
ios-sim    : 6.1.2
Node       : v10.4.1
npm        : 6.1.0
OS         : macOS High Sierra
Xcode      : Xcode 9.3.1 Build version 9E501

Environment Variables:

ANDROID_HOME : not set

Misc:

backend : pro



Other information:

Feature request

Documentation issue

dpa99c commented 6 years ago

From your description, I'm not quite clear on what the issue is.

Once the user has chosen a preferred app, the remembered choice can be cleared by calling appSelection.userChoice.clear().

Are you saying calling this function on Android isn't clearing the user choice?

Holbanner commented 6 years ago

Hi, Not really what i meant. I'll try to be a bit more clear. I mean that in most case when you select a default app be it to open a map or to open a calendar or to browse the web, if the user feels like changing app he can go to Android/Ios setting page -> go to either a page that is general for default apps or go to a specific app and then choose what default app opens what.

But when i do that with apps using this plugin, I can't manage this setting.

From your answer I kind of understand that the plugin doesn't actually switch the native settings? But rather create a local setting, right?

dpa99c commented 6 years ago

Yes, the preference is stored locally within the app that contains the plugin.

I don't know of any native Android/iOS API to enable you to set/clear the default app used by the OS from a 3rd app - I don't think it can be done.

Holbanner commented 6 years ago

Right, my bad. I misunderstood and thought that the dialog was the native setting dialog.

Kind of how the plug-in open-native-setting just opens the settings page of your phone. From memory it could more or less target a precise setting page so the user could manually switch autorisations for exemple

Le mar. 3 juil. 2018 à 13:01, Dave Alden notifications@github.com a écrit :

Yes, the preference is stored locally within the app that contains the plugin.

I don't know of any native Android/iOS API to enable you to set/clear the default app used by the OS from a 3rd app - I don't think it can be done.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/dpa99c/phonegap-launch-navigator/issues/196#issuecomment-402110393, or mute the thread https://github.com/notifications/unsubscribe-auth/AVjB2YRTrfwXm3olSZedyM1ErqkZIIZXks5uC08VgaJpZM4VAkL6 .

dpa99c commented 6 years ago

From memory it could more or less target a precise setting page so the user could manually switch autorisations for exemple

It could, but this requires manual user action, whereas the current implementation allows the preference to be controlled from within the app that's using the plugin: a simple button to clear their current preference. Therefore, I don't see a good reason to switch over to using native settings where the user needs to manually set the preference. On that basis, I will close this as an issue.

Holbanner commented 6 years ago

Agreed

Le mar. 3 juil. 2018 à 13:13, Dave Alden notifications@github.com a écrit :

From memory it could more or less target a precise setting page so the user could manually switch autorisations for exemple

It could, but this requires manual user action, whereas the current implementation allows the preference to be controlled from within the app that's using the plugin: a simple button to clear their current preference. Therefore, I don't see a good reason to switch over to using native settings where the user needs to manually set the preference. On that basis, I will close this as an issue.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/dpa99c/phonegap-launch-navigator/issues/196#issuecomment-402114955, or mute the thread https://github.com/notifications/unsubscribe-auth/AVjB2XXm8aPeBdbZMZupOeBuEyeTOAKWks5uC1H3gaJpZM4VAkL6 .