Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
permission_handler
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
songyanzhi
permission_handler
Commits
71a9dd71
Commit
71a9dd71
authored
Jun 10, 2021
by
Neal Soni
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add criticalAlerts for iOS and accessNotificationPolicy for Android to Permissions
parent
274247d0
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
4 deletions
+17
-4
permission_handler_platform_interface/lib/src/permissions.dart
+15
-2
permission_handler_platform_interface/pubspec.yaml
+1
-1
permission_handler_platform_interface/test/src/permissions_test.dart
+1
-1
No files found.
permission_handler_platform_interface/lib/src/permissions.dart
View file @
71a9dd71
...
@@ -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
...
...
permission_handler_platform_interface/pubspec.yaml
View file @
71a9dd71
...
@@ -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
:
...
...
permission_handler_platform_interface/test/src/permissions_test.dart
View file @
71a9dd71
...
@@ -6,7 +6,7 @@ void main() {
...
@@ -6,7 +6,7 @@ void main() {
()
{
()
{
final
values
=
Permission
.
values
;
final
values
=
Permission
.
values
;
expect
(
values
.
length
,
2
6
);
expect
(
values
.
length
,
2
8
);
});
});
test
(
'check if byValue returns corresponding PermissionGroup value'
,
()
{
test
(
'check if byValue returns corresponding PermissionGroup value'
,
()
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment