The Tizen implementation of permisson_handler
.
You can use this plugin to ask the user for runtime permissions if your app performs security-sensitive operations or access restricted data.
-
Declare necessary privileges in your
tizen-manifest.xml
file by referring to the below permission list. For example, if you want to access the device's media library in your Flutter app, add:<privileges> <privilege>http://tizen.org/privilege/mediastorage</privilege> </privileges>
-
Add
permission_handler
andpermission_handler_tizen
as dependencies in yourpubspec.yaml
file.dependencies: permission_handler: ^10.4.3 permission_handler_tizen: ^1.3.0
Then you can import
permission_handler
in your Dart code:import 'package:permission_handler/permission_handler.dart';
For detailed usage, see https://pub.dev/packages/permission_handler#how-to-use.
Permission | Tizen permission | Tizen privileges |
---|---|---|
Permission.calendar |
Calendar | http://tizen.org/privilege/calendar.read http://tizen.org/privilege/calendar.write |
Permission.camera |
Camera | http://tizen.org/privilege/camera |
Permission.contact |
Contacts | http://tizen.org/privilege/contact.read http://tizen.org/privilege/contact.write |
Permission.location Permission.locationAlways Permission.locationWhenInUse |
Location | http://tizen.org/privilege/location http://tizen.org/privilege/location.coarse |
Permission.mediaLibrary |
Storage | http://tizen.org/privilege/mediastorage |
Permission.microphone |
Microphone | http://tizen.org/privilege/recorder |
Permission.phone |
Call | http://tizen.org/privilege/call |
Permission.sensors Permission.sensorsAlways |
Sensor | http://tizen.org/privilege/healthinfo |
Permission.sms |
Message | http://tizen.org/privilege/message.read http://tizen.org/privilege/message.write |
Permission.storage |
Storage | http://tizen.org/privilege/externalstorage |
The following permissions are not applicable for Tizen:
- Android-only:
accessMediaLocation
,accessNotificationPolicy
,activityRecognition
,audio
,bluetoothAdvertise
,bluetoothConnect
,bluetoothScan
,ignoreBatteryOptimizations
,manageExternalStorage
,nearbyWifiDevices
,requestInstallPackages
,scheduleExactAlarm
,systemAlertWindow
,videos
- iOS-only:
appTrackingTransparency
,criticalAlerts
,photosAddOnly
,reminders
,speech
On Tizen, your app can use some security-sensitive features (such as bluetooth) without explicitly acquiring permissions. However, you might need to declare relevant privileges in its tizen-manifest.xml
file. For detailed information on Tizen privileges, see Tizen Docs: API Privileges.
- Galaxy Watch series (running Tizen 5.5)
On TV devices, you don't need to explicitly request permissions since they are already granted to apps by default.
-
Permission.status
(including shortcuts such asPermission.isGranted
andPermission.isPermanentlyDenied
) -
Permission.serviceStatus
-
Permission.shouldShowRequestRationale
(Android-only) -
Permission.request
-
List<Permission>.request
-
openAppSettings
(not supported on emulators)