| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_UI_WEBSITE_SETTINGS_PERMISSION_BUBBLE_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBSITE_SETTINGS_PERMISSION_BUBBLE_MANAGER_H_ |
| 6 #define CHROME_BROWSER_UI_WEBSITE_SETTINGS_PERMISSION_BUBBLE_MANAGER_H_ | 6 #define CHROME_BROWSER_UI_WEBSITE_SETTINGS_PERMISSION_BUBBLE_MANAGER_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 void SetView(PermissionBubbleView* view) override; | 59 void SetView(PermissionBubbleView* view) override; |
| 60 | 60 |
| 61 // Controls whether incoming permission requests require user gestures. | 61 // Controls whether incoming permission requests require user gestures. |
| 62 // If |required| is false, requests will be displayed as soon as they come in. | 62 // If |required| is false, requests will be displayed as soon as they come in. |
| 63 // If |required| is true, requests will be silently queued until a request | 63 // If |required| is true, requests will be silently queued until a request |
| 64 // comes in with a user gesture. | 64 // comes in with a user gesture. |
| 65 void RequireUserGesture(bool required); | 65 void RequireUserGesture(bool required); |
| 66 | 66 |
| 67 private: | 67 private: |
| 68 friend class DownloadRequestLimiterTest; | 68 friend class DownloadRequestLimiterTest; |
| 69 friend class GeolocationBrowserTest; | |
| 70 friend class GeolocationPermissionContextTests; | |
| 71 friend class GeolocationPermissionContextParamTests; | |
| 72 friend class PermissionBubbleManagerTest; | 69 friend class PermissionBubbleManagerTest; |
| 73 friend class PermissionContextBaseTests; | 70 friend class PermissionContextBaseTests; |
| 74 friend class content::WebContentsUserData<PermissionBubbleManager>; | 71 friend class content::WebContentsUserData<PermissionBubbleManager>; |
| 75 | 72 |
| 76 explicit PermissionBubbleManager(content::WebContents* web_contents); | 73 explicit PermissionBubbleManager(content::WebContents* web_contents); |
| 77 | 74 |
| 78 // WebContentsObserver: | 75 // WebContentsObserver: |
| 79 void DocumentOnLoadCompletedInMainFrame() override; | 76 void DocumentOnLoadCompletedInMainFrame() override; |
| 80 void DocumentLoadedInFrame( | 77 void DocumentLoadedInFrame( |
| 81 content::RenderFrameHost* render_frame_host) override; | 78 content::RenderFrameHost* render_frame_host) override; |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 139 GURL request_url_; | 136 GURL request_url_; |
| 140 bool request_url_has_loaded_; | 137 bool request_url_has_loaded_; |
| 141 | 138 |
| 142 std::vector<bool> accept_states_; | 139 std::vector<bool> accept_states_; |
| 143 bool customization_mode_; | 140 bool customization_mode_; |
| 144 | 141 |
| 145 base::WeakPtrFactory<PermissionBubbleManager> weak_factory_; | 142 base::WeakPtrFactory<PermissionBubbleManager> weak_factory_; |
| 146 }; | 143 }; |
| 147 | 144 |
| 148 #endif // CHROME_BROWSER_UI_WEBSITE_SETTINGS_PERMISSION_BUBBLE_MANAGER_H_ | 145 #endif // CHROME_BROWSER_UI_WEBSITE_SETTINGS_PERMISSION_BUBBLE_MANAGER_H_ |
| OLD | NEW |