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 WebFrameScheduler_h | 5 #ifndef WebFrameScheduler_h |
6 #define WebFrameScheduler_h | 6 #define WebFrameScheduler_h |
7 | 7 |
8 #include "platform/wtf/RefPtr.h" | 8 #include "platform/wtf/RefPtr.h" |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
44 virtual void SetCrossOrigin(bool) {} | 44 virtual void SetCrossOrigin(bool) {} |
45 | 45 |
46 // Returns the WebTaskRunner for loading tasks. | 46 // Returns the WebTaskRunner for loading tasks. |
47 // WebFrameScheduler owns the returned WebTaskRunner. | 47 // WebFrameScheduler owns the returned WebTaskRunner. |
48 virtual RefPtr<WebTaskRunner> LoadingTaskRunner() = 0; | 48 virtual RefPtr<WebTaskRunner> LoadingTaskRunner() = 0; |
49 | 49 |
50 // Returns the WebTaskRunner for timer tasks. | 50 // Returns the WebTaskRunner for timer tasks. |
51 // WebFrameScheduler owns the returned WebTaskRunner. | 51 // WebFrameScheduler owns the returned WebTaskRunner. |
52 virtual RefPtr<WebTaskRunner> TimerTaskRunner() = 0; | 52 virtual RefPtr<WebTaskRunner> TimerTaskRunner() = 0; |
53 | 53 |
54 // Returns the WebTaskRunner for compositor tasks. | |
55 // WebFrameScheduler owns the returned WebTaskRunner. | |
Sami
2017/04/27 17:38:17
Hmm, this comment about ownership doesn't make sen
Dan Elphick
2017/05/03 09:41:06
no longer required
| |
56 virtual RefPtr<WebTaskRunner> CompositorTaskRunner() = 0; | |
57 | |
54 // Returns the WebTaskRunner for tasks which shouldn't get throttled, | 58 // Returns the WebTaskRunner for tasks which shouldn't get throttled, |
55 // but can be suspended. | 59 // but can be suspended. |
56 // TODO(altimin): This is a transitional task runner. Unthrottled task runner | 60 // TODO(altimin): This is a transitional task runner. Unthrottled task runner |
57 // would become suspendable in the nearest future and a new unsuspended | 61 // would become suspendable in the nearest future and a new unsuspended |
58 // task runner will be added. | 62 // task runner will be added. |
59 virtual RefPtr<WebTaskRunner> SuspendableTaskRunner() = 0; | 63 virtual RefPtr<WebTaskRunner> SuspendableTaskRunner() = 0; |
60 | 64 |
61 // Returns the WebTaskRunner for tasks which should never get throttled. | 65 // Returns the WebTaskRunner for tasks which should never get throttled. |
62 // This is generally used for executing internal browser tasks which should | 66 // This is generally used for executing internal browser tasks which should |
63 // never be throttled. Ideally only tasks whose performance characteristics | 67 // never be throttled. Ideally only tasks whose performance characteristics |
(...skipping 26 matching lines...) Expand all Loading... | |
90 // connection (websocket, webrtc, etc). When connection is closed this handle | 94 // connection (websocket, webrtc, etc). When connection is closed this handle |
91 // must be destroyed. | 95 // must be destroyed. |
92 virtual std::unique_ptr<ActiveConnectionHandle> OnActiveConnectionCreated() { | 96 virtual std::unique_ptr<ActiveConnectionHandle> OnActiveConnectionCreated() { |
93 return nullptr; | 97 return nullptr; |
94 }; | 98 }; |
95 }; | 99 }; |
96 | 100 |
97 } // namespace blink | 101 } // namespace blink |
98 | 102 |
99 #endif // WebFrameScheduler_h | 103 #endif // WebFrameScheduler_h |
OLD | NEW |