g123k / flutter_torch_compat

A plugin to enable or disable the torch of a device that works both on Android (including Android 4.x) and iOS.
https://pub.dev/packages/torch_compat
Apache License 2.0
7 stars 22 forks source link

we do not need the camera permissions to operate the flashlight #12

Closed jeffmikels closed 3 years ago

jeffmikels commented 3 years ago

we do not need the camera permissions to operate the flashlight

g123k commented 3 years ago

I would love to merge your PR @jeffmikels, unfortunately in many cases changing the current behavior will make some devices crashes. For instance: https://stackoverflow.com/questions/36259930/which-permissions-are-required-for-flashlight

I'm really sorry

jeffmikels commented 3 years ago

That thread was from 2016. Today, Android permissions are much more explicit, and requesting camera permissions when you only need the flashlight is the wrong way to go.

g123k commented 3 years ago

But the library have to support older versions of android.

On Mon, Jan 25, 2021 at 8:10 PM jeffmikels notifications@github.com wrote:

That thread was from 2016. Today, Android permissions are much more explicit, and requesting camera permissions when you only need the flashlight is the wrong way to go.

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/g123k/flutter_torch_compat/pull/12#issuecomment-767046032, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAB4INTQWOY5RIERS7FCXGDS3W627ANCNFSM4SRAVRVA .

jeffmikels commented 3 years ago

I just modified my branch to include instructions in the README.