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 CONTENT_RENDERER_PEPPER_PLUGIN_POWER_SAVER_HELPER_H_ | 5 #ifndef CONTENT_RENDERER_PEPPER_PLUGIN_POWER_SAVER_HELPER_H_ |
6 #define CONTENT_RENDERER_PEPPER_PLUGIN_POWER_SAVER_HELPER_H_ | 6 #define CONTENT_RENDERER_PEPPER_PLUGIN_POWER_SAVER_HELPER_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
50 RenderFrame::PeripheralContentStatus GetPeripheralContentStatus( | 50 RenderFrame::PeripheralContentStatus GetPeripheralContentStatus( |
51 const url::Origin& main_frame_origin, | 51 const url::Origin& main_frame_origin, |
52 const url::Origin& content_origin, | 52 const url::Origin& content_origin, |
53 const gfx::Size& unobscured_size) const; | 53 const gfx::Size& unobscured_size) const; |
54 void WhitelistContentOrigin(const url::Origin& content_origin); | 54 void WhitelistContentOrigin(const url::Origin& content_origin); |
55 | 55 |
56 // RenderFrameObserver implementation. | 56 // RenderFrameObserver implementation. |
57 void DidCommitProvisionalLoad(bool is_new_navigation, | 57 void DidCommitProvisionalLoad(bool is_new_navigation, |
58 bool is_same_page_navigation) override; | 58 bool is_same_page_navigation) override; |
59 bool OnMessageReceived(const IPC::Message& message) override; | 59 bool OnMessageReceived(const IPC::Message& message) override; |
| 60 void OnDestruct() override; |
60 | 61 |
61 void OnUpdatePluginContentOriginWhitelist( | 62 void OnUpdatePluginContentOriginWhitelist( |
62 const std::set<url::Origin>& origin_whitelist); | 63 const std::set<url::Origin>& origin_whitelist); |
63 | 64 |
64 // Local copy of the whitelist for the entire tab. | 65 // Local copy of the whitelist for the entire tab. |
65 std::set<url::Origin> origin_whitelist_; | 66 std::set<url::Origin> origin_whitelist_; |
66 | 67 |
67 // Set of peripheral plugins eligible to be unthrottled ex post facto. | 68 // Set of peripheral plugins eligible to be unthrottled ex post facto. |
68 std::vector<PeripheralPlugin> peripheral_plugins_; | 69 std::vector<PeripheralPlugin> peripheral_plugins_; |
69 | 70 |
70 DISALLOW_COPY_AND_ASSIGN(PluginPowerSaverHelper); | 71 DISALLOW_COPY_AND_ASSIGN(PluginPowerSaverHelper); |
71 }; | 72 }; |
72 | 73 |
73 } // namespace content | 74 } // namespace content |
74 | 75 |
75 #endif // CONTENT_RENDERER_PEPPER_PLUGIN_POWER_SAVER_HELPER_H_ | 76 #endif // CONTENT_RENDERER_PEPPER_PLUGIN_POWER_SAVER_HELPER_H_ |
OLD | NEW |