DEV Community

Alexandre Freire
Alexandre Freire

Posted on

1

Flutter ImagePicker: Permissões de Câmera e Galeria no iOS

Recentemente, o plugin ImagePicker começou a exigir que as permissões de Câmera e Galeria no iOS fossem identificadas. Pra fazer isso, basta adicionar apenas 6 linhas ao seu info.plist, que fica localizado na pasta ios/Runner.

Ao final do arquivo, antes do "< / dict >", cole as 6 linhas, como demonstrado abaixo:

    <key>NSPhotoLibraryUsageDescription</key>        // COLE ESTA E AS OUTRAS 5 LINHAS ABAIXO
    <string>Tirar fotos dos contatos.</string>
    <key>NSCameraUsageDescription</key>
    <string>Selecionar uma foto de contato da galeria.</string>
    <key>NSMicrophoneUsageDescription</key>
    <string>Tirar fotos dos contatos.</string>
</dict>  
Enter fullscreen mode Exit fullscreen mode

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay