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

Side by Side Diff: chrome/browser/permissions/permission_manager.h

Issue 1158813002: Use RenderFrameHost for ::RequestPermission() and ::CancelPermission(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: build fixes Created 5 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_PERMISSIONS_PERMISSION_MANAGER_H_ 5 #ifndef CHROME_BROWSER_PERMISSIONS_PERMISSION_MANAGER_H_
6 #define CHROME_BROWSER_PERMISSIONS_PERMISSION_MANAGER_H_ 6 #define CHROME_BROWSER_PERMISSIONS_PERMISSION_MANAGER_H_
7 7
8 #include "base/callback_forward.h" 8 #include "base/callback_forward.h"
9 #include "base/id_map.h" 9 #include "base/id_map.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 11 matching lines...) Expand all
22 class PermissionManager : public KeyedService, 22 class PermissionManager : public KeyedService,
23 public content::PermissionManager, 23 public content::PermissionManager,
24 public content_settings::Observer { 24 public content_settings::Observer {
25 public: 25 public:
26 explicit PermissionManager(Profile* profile); 26 explicit PermissionManager(Profile* profile);
27 ~PermissionManager() override; 27 ~PermissionManager() override;
28 28
29 // content::PermissionManager implementation. 29 // content::PermissionManager implementation.
30 void RequestPermission( 30 void RequestPermission(
31 content::PermissionType permission, 31 content::PermissionType permission,
32 content::WebContents* web_contents, 32 content::RenderFrameHost* render_frame_host,
33 int request_id, 33 int request_id,
34 const GURL& requesting_origin, 34 const GURL& requesting_origin,
35 bool user_gesture, 35 bool user_gesture,
36 const base::Callback<void(content::PermissionStatus)>& callback) override; 36 const base::Callback<void(content::PermissionStatus)>& callback) override;
37 void CancelPermissionRequest(content::PermissionType permission, 37 void CancelPermissionRequest(content::PermissionType permission,
38 content::WebContents* web_contents, 38 content::RenderFrameHost* render_frame_host,
39 int request_id, 39 int request_id,
40 const GURL& requesting_origin) override; 40 const GURL& requesting_origin) override;
41 void ResetPermission(content::PermissionType permission, 41 void ResetPermission(content::PermissionType permission,
42 const GURL& requesting_origin, 42 const GURL& requesting_origin,
43 const GURL& embedding_origin) override; 43 const GURL& embedding_origin) override;
44 content::PermissionStatus GetPermissionStatus( 44 content::PermissionStatus GetPermissionStatus(
45 content::PermissionType permission, 45 content::PermissionType permission,
46 const GURL& requesting_origin, 46 const GURL& requesting_origin,
47 const GURL& embedding_origin) override; 47 const GURL& embedding_origin) override;
48 void RegisterPermissionUsage(content::PermissionType permission, 48 void RegisterPermissionUsage(content::PermissionType permission,
(...skipping 16 matching lines...) Expand all
65 ContentSettingsType content_type, 65 ContentSettingsType content_type,
66 std::string resource_identifier) override; 66 std::string resource_identifier) override;
67 67
68 Profile* profile_; 68 Profile* profile_;
69 SubscriptionsMap subscriptions_; 69 SubscriptionsMap subscriptions_;
70 70
71 DISALLOW_COPY_AND_ASSIGN(PermissionManager); 71 DISALLOW_COPY_AND_ASSIGN(PermissionManager);
72 }; 72 };
73 73
74 #endif // CHROME_BROWSER_PERMISSIONS_PERMISSION_MANAGER_H_ 74 #endif // CHROME_BROWSER_PERMISSIONS_PERMISSION_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698