Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1323)

Unified Diff: content/shell/browser/shell_permission_manager.cc

Issue 1419083002: Permissions: browser/ side implementation of multiple permissions request. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/shell/browser/shell_permission_manager.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/shell/browser/shell_permission_manager.cc
diff --git a/content/shell/browser/shell_permission_manager.cc b/content/shell/browser/shell_permission_manager.cc
index e8e3e71fc72247e3fbebfc35cf9f9e4949dd0c65..fb537b027b828c08dbaed6c7a00d346d58914de9 100644
--- a/content/shell/browser/shell_permission_manager.cc
+++ b/content/shell/browser/shell_permission_manager.cc
@@ -30,6 +30,22 @@ int ShellPermissionManager::RequestPermission(
return kNoPendingOperation;
}
+int ShellPermissionManager::RequestPermissions(
+ const std::vector<PermissionType>& permissions,
+ content::RenderFrameHost* render_frame_host,
+ const GURL& requesting_origin,
+ bool user_gesture,
+ const base::Callback<void(
+ const std::vector<PermissionStatus>&)>& callback) {
+ std::vector<PermissionStatus> result(permissions.size());
+ for (const auto& permission : permissions) {
+ result.push_back(permission == PermissionType::GEOLOCATION
+ ? PERMISSION_STATUS_GRANTED : PERMISSION_STATUS_DENIED);
+ }
+ callback.Run(result);
+ return kNoPendingOperation;
+}
+
void ShellPermissionManager::CancelPermissionRequest(int request_id) {
}
« no previous file with comments | « content/shell/browser/shell_permission_manager.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698