Index: components/permission/public/interfaces/permission.mojom |
diff --git a/content/common/permission_service.mojom b/components/permission/public/interfaces/permission.mojom |
similarity index 57% |
rename from content/common/permission_service.mojom |
rename to components/permission/public/interfaces/permission.mojom |
index 5a6178793c5def6affd9212b9ece19c2fb720c89..50c2e4d01298361836b87203828f2584b86ddc0d 100644 |
--- a/content/common/permission_service.mojom |
+++ b/components/permission/public/interfaces/permission.mojom |
@@ -2,11 +2,11 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-module content; |
+module permission; |
-import "content/public/common/permission_status.mojom"; |
+import "components/permission/public/interfaces/permission_status.mojom"; |
-enum PermissionName { |
+enum Name { |
GEOLOCATION, |
NOTIFICATIONS, |
PUSH_NOTIFICATIONS, |
@@ -22,21 +22,21 @@ enum PermissionName { |
// methods to check, request, and revoke permissions. It also allows a client to |
// start listening to permission changes. |
interface PermissionService { |
- HasPermission(PermissionName permission, string origin) |
- => (PermissionStatus status); |
- RequestPermission(PermissionName permission, string origin, bool user_gesture) |
- => (PermissionStatus status); |
- RequestPermissions(array<PermissionName> permission, string origin, bool user_gesture) |
- => (array<PermissionStatus> statuses); |
- RevokePermission(PermissionName permission, string origin) |
- => (PermissionStatus status); |
+ HasPermission(Name permission, string origin) |
+ => (Status status); |
+ RequestPermission(Name permission, string origin, bool user_gesture) |
+ => (Status status); |
+ RequestPermissions(array<Name> permission, string origin, bool user_gesture) |
+ => (array<Status> statuses); |
+ RevokePermission(Name permission, string origin) |
+ => (Status status); |
// Runs the callback next time there is a permission status change for the |
// given { permission, origin }. Callers of this method will have to call it |
// again if they want to keep listening to the changes. To prevent race |
// conditions, the caller must pass the last known value. |
- GetNextPermissionChange(PermissionName permission, |
+ GetNextPermissionChange(Name permission, |
string origin, |
- PermissionStatus last_known_status) |
- => (PermissionStatus status); |
+ Status last_known_status) |
+ => (Status status); |
}; |