Commit ea1097ad by Maurits van Beusekom Committed by GitHub

Merge pull request #590 from InvictusApps/critical-alerts-and-notification-policy

parents 274247d0 feda060c
## 3.6.0
* Add support for iOS Critical alerts and Android Access Notification Policy.
## 3.5.1 ## 3.5.1
* Updated API documentation for the `PermissionStatus.permanentlyDenied` status. * Updated API documentation for the `PermissionStatus.permanentlyDenied` status.
......
...@@ -143,6 +143,15 @@ class Permission { ...@@ -143,6 +143,15 @@ class Permission {
///websites. ///websites.
static const appTrackingTransparency = Permission._(25); static const appTrackingTransparency = Permission._(25);
///Android: Nothing
///iOS: Notifications that override your ringer
static const criticalAlerts = Permission._(26);
///Android: Allows the user to access the notification policy of the phone.
/// EX: Allows app to turn on and off do-not-disturb.
///iOS: Nothing
static const accessNotificationPolicy = Permission._(27);
/// Returns a list of all possible [PermissionGroup] values. /// Returns a list of all possible [PermissionGroup] values.
static const List<Permission> values = <Permission>[ static const List<Permission> values = <Permission>[
calendar, calendar,
...@@ -170,7 +179,9 @@ class Permission { ...@@ -170,7 +179,9 @@ class Permission {
manageExternalStorage, manageExternalStorage,
systemAlertWindow, systemAlertWindow,
requestInstallPackages, requestInstallPackages,
appTrackingTransparency appTrackingTransparency,
criticalAlerts,
accessNotificationPolicy,
]; ];
static const List<String> _names = <String>[ static const List<String> _names = <String>[
...@@ -199,7 +210,9 @@ class Permission { ...@@ -199,7 +210,9 @@ class Permission {
'manageExternalStorage', 'manageExternalStorage',
'systemAlertWindow', 'systemAlertWindow',
'requestInstallPackages', 'requestInstallPackages',
'appTrackingTransparency' 'appTrackingTransparency',
'criticalAlerts',
'accessNotificationPolicy',
]; ];
@override @override
......
...@@ -3,7 +3,7 @@ description: A common platform interface for the permission_handler plugin. ...@@ -3,7 +3,7 @@ description: A common platform interface for the permission_handler plugin.
homepage: https://github.com/baseflow/flutter-permission-handler/tree/master/permission_handler_platform_interface homepage: https://github.com/baseflow/flutter-permission-handler/tree/master/permission_handler_platform_interface
# NOTE: We strongly prefer non-breaking changes, even at the expense of a # NOTE: We strongly prefer non-breaking changes, even at the expense of a
# less-clean API. See https://flutter.dev/go/platform-interface-breaking-changes # less-clean API. See https://flutter.dev/go/platform-interface-breaking-changes
version: 3.5.1 version: 3.6.0
dependencies: dependencies:
flutter: flutter:
......
...@@ -6,7 +6,7 @@ void main() { ...@@ -6,7 +6,7 @@ void main() {
() { () {
final values = Permission.values; final values = Permission.values;
expect(values.length, 26); expect(values.length, 28);
}); });
test('check if byValue returns corresponding PermissionGroup value', () { test('check if byValue returns corresponding PermissionGroup value', () {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment