Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature request] Opt-out of permission handling #177

Open
itsJoKr opened this issue May 14, 2021 · 2 comments
Open

[Feature request] Opt-out of permission handling #177

itsJoKr opened this issue May 14, 2021 · 2 comments

Comments

@itsJoKr
Copy link

itsJoKr commented May 14, 2021

For a good user experience, handling the permission is never just that one native permission dialog.
It would also include some UI when you deny, and a different UI when it's permanently denied that will help the user to open the settings, usually with some nice graphics...

It's almost impossible to build this kind of experience because this package will control permissions. Two biggest problems I've encountered:

  1. When I ask for permission, the package will also react to callback and ask for permission for some reason.
  2. When the user denies the permission I will get an onError, but I don't get info if the user denied or permanently denied so I cannot show appropriate UI (without asking for permission again by myself).

I think the easiest thing would be a parameter, something like QrCamera(dontHandlePermissions: true) that will let me handle the permissions as I want them.

What do you think?

@octaviodivy
Copy link

Updates here?

@rmtmckenzie
Copy link
Owner

I don't currently have much time to spend working on this, but would gladly accept a PR. Realistically, I put the permissions handling in just as a stop-gap and it was never really intended to be an all-round solution (and when I first made this, there was no good flutter alternative).

Can you elaborate on your first point? What exactly is going on there, this plugin is doing something with the permissions even though you used something external to request them?

What I'd recommend is using a different plugin for permission handling as they should allow you to do things like see if it has been permanently denied, before using this plugin. If there are compatibility issues that would definitely be something I'd like to fix though, and maybe I should be taking out the permission stuff entirely.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants