photos static method
void
photos(
- dynamic onGranted()
Implementation
static void photos(Function() onGranted) async {
if (await Permission.photos.request().isGranted) {
// Either the permission was already granted before or the user just granted it.
onGranted();
}
if (await Permission.photos.isPermanentlyDenied) {
// The user opted to never again see the permission request dialog for this
// app. The only way to change the permission's status now is to let the
// user manually enable it in the system settings.
}
}