OLD | NEW |
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 COMPONENTS_SCHEDULER_RENDERER_WEB_VIEW_SCHEDULER_IMPL_H_ | 5 #ifndef COMPONENTS_SCHEDULER_RENDERER_WEB_VIEW_SCHEDULER_IMPL_H_ |
6 #define COMPONENTS_SCHEDULER_RENDERER_WEB_VIEW_SCHEDULER_IMPL_H_ | 6 #define COMPONENTS_SCHEDULER_RENDERER_WEB_VIEW_SCHEDULER_IMPL_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 22 matching lines...) Expand all Loading... |
33 WebViewSchedulerImpl(blink::WebView* web_view, | 33 WebViewSchedulerImpl(blink::WebView* web_view, |
34 RendererSchedulerImpl* renderer_scheduler, | 34 RendererSchedulerImpl* renderer_scheduler, |
35 bool disable_background_timer_throttling); | 35 bool disable_background_timer_throttling); |
36 | 36 |
37 ~WebViewSchedulerImpl() override; | 37 ~WebViewSchedulerImpl() override; |
38 | 38 |
39 // blink::WebViewScheduler implementation: | 39 // blink::WebViewScheduler implementation: |
40 void setPageVisible(bool page_visible) override; | 40 void setPageVisible(bool page_visible) override; |
41 blink::WebPassOwnPtr<blink::WebFrameScheduler> createFrameScheduler() | 41 blink::WebPassOwnPtr<blink::WebFrameScheduler> createFrameScheduler() |
42 override; | 42 override; |
43 | 43 void enableVirtualTime() override; |
44 // TODO(alexclarke): Expose in blink::WebViewScheduler. | |
45 void enableVirtualTime(); | |
46 void setAllowVirtualTimeToAdvance( | 44 void setAllowVirtualTimeToAdvance( |
47 bool allow_virtual_time_to_advance); | 45 bool allow_virtual_time_to_advance) override; |
48 | 46 |
49 // Virtual for testing. | 47 // Virtual for testing. |
50 virtual void AddConsoleWarning(const std::string& message); | 48 virtual void AddConsoleWarning(const std::string& message); |
51 | 49 |
52 scoped_ptr<WebFrameSchedulerImpl> createWebFrameSchedulerImpl(); | 50 scoped_ptr<WebFrameSchedulerImpl> createWebFrameSchedulerImpl(); |
53 | 51 |
54 private: | 52 private: |
55 friend class WebFrameSchedulerImpl; | 53 friend class WebFrameSchedulerImpl; |
56 | 54 |
57 void Unregister(WebFrameSchedulerImpl* frame_scheduler); | 55 void Unregister(WebFrameSchedulerImpl* frame_scheduler); |
(...skipping 10 matching lines...) Expand all Loading... |
68 bool page_visible_; | 66 bool page_visible_; |
69 bool disable_background_timer_throttling_; | 67 bool disable_background_timer_throttling_; |
70 bool allow_virtual_time_to_advance_; | 68 bool allow_virtual_time_to_advance_; |
71 | 69 |
72 DISALLOW_COPY_AND_ASSIGN(WebViewSchedulerImpl); | 70 DISALLOW_COPY_AND_ASSIGN(WebViewSchedulerImpl); |
73 }; | 71 }; |
74 | 72 |
75 } // namespace scheduler | 73 } // namespace scheduler |
76 | 74 |
77 #endif // COMPONENTS_SCHEDULER_RENDERER_WEB_VIEW_SCHEDULER_IMPL_H_ | 75 #endif // COMPONENTS_SCHEDULER_RENDERER_WEB_VIEW_SCHEDULER_IMPL_H_ |
OLD | NEW |