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

Side by Side Diff: cc/test/proxy_main_for_test.h

Issue 1866203004: Convert //cc from scoped_ptr to std::unique_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: scopedptrcc: rebase Created 4 years, 8 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
« no previous file with comments | « cc/test/proxy_impl_for_test.cc ('k') | cc/test/proxy_main_for_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 CC_TEST_PROXY_MAIN_FOR_TEST_H_ 5 #ifndef CC_TEST_PROXY_MAIN_FOR_TEST_H_
6 #define CC_TEST_PROXY_MAIN_FOR_TEST_H_ 6 #define CC_TEST_PROXY_MAIN_FOR_TEST_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "cc/test/test_hooks.h" 9 #include "cc/test/test_hooks.h"
10 #include "cc/trees/proxy_main.h" 10 #include "cc/trees/proxy_main.h"
11 11
12 namespace cc { 12 namespace cc {
13 class ThreadedChannelForTest; 13 class ThreadedChannelForTest;
14 14
15 // Creates a ProxyMain that notifies the supplied |test_hooks| of various 15 // Creates a ProxyMain that notifies the supplied |test_hooks| of various
16 // actions. 16 // actions.
17 class ProxyMainForTest : public ProxyMain { 17 class ProxyMainForTest : public ProxyMain {
18 public: 18 public:
19 static scoped_ptr<ProxyMainForTest> CreateThreaded( 19 static std::unique_ptr<ProxyMainForTest> CreateThreaded(
20 TestHooks* test_hooks, 20 TestHooks* test_hooks,
21 LayerTreeHost* host, 21 LayerTreeHost* host,
22 TaskRunnerProvider* task_runner_provider); 22 TaskRunnerProvider* task_runner_provider);
23 23
24 static scoped_ptr<ProxyMainForTest> CreateRemote( 24 static std::unique_ptr<ProxyMainForTest> CreateRemote(
25 TestHooks* test_hooks, 25 TestHooks* test_hooks,
26 RemoteProtoChannel* remote_proto_channel, 26 RemoteProtoChannel* remote_proto_channel,
27 LayerTreeHost* host, 27 LayerTreeHost* host,
28 TaskRunnerProvider* task_runner_provider); 28 TaskRunnerProvider* task_runner_provider);
29 29
30 ~ProxyMainForTest() override; 30 ~ProxyMainForTest() override;
31 31
32 ProxyMainForTest(TestHooks* test_hooks, 32 ProxyMainForTest(TestHooks* test_hooks,
33 LayerTreeHost* host, 33 LayerTreeHost* host,
34 TaskRunnerProvider* task_runner_provider); 34 TaskRunnerProvider* task_runner_provider);
35 35
36 ThreadedChannelForTest* threaded_channel_for_test() const { 36 ThreadedChannelForTest* threaded_channel_for_test() const {
37 return threaded_channel_for_test_; 37 return threaded_channel_for_test_;
38 } 38 }
39 39
40 void SetNeedsUpdateLayers() override; 40 void SetNeedsUpdateLayers() override;
41 void DidCompleteSwapBuffers() override; 41 void DidCompleteSwapBuffers() override;
42 void SetRendererCapabilities( 42 void SetRendererCapabilities(
43 const RendererCapabilities& capabilities) override; 43 const RendererCapabilities& capabilities) override;
44 void BeginMainFrameNotExpectedSoon() override; 44 void BeginMainFrameNotExpectedSoon() override;
45 void DidCommitAndDrawFrame() override; 45 void DidCommitAndDrawFrame() override;
46 void SetAnimationEvents(scoped_ptr<AnimationEvents> events) override; 46 void SetAnimationEvents(std::unique_ptr<AnimationEvents> events) override;
47 void DidLoseOutputSurface() override; 47 void DidLoseOutputSurface() override;
48 void RequestNewOutputSurface() override; 48 void RequestNewOutputSurface() override;
49 void DidInitializeOutputSurface( 49 void DidInitializeOutputSurface(
50 bool success, 50 bool success,
51 const RendererCapabilities& capabilities) override; 51 const RendererCapabilities& capabilities) override;
52 void DidCompletePageScaleAnimation() override; 52 void DidCompletePageScaleAnimation() override;
53 void PostFrameTimingEventsOnMain( 53 void PostFrameTimingEventsOnMain(
54 scoped_ptr<FrameTimingTracker::CompositeTimingSet> composite_events, 54 std::unique_ptr<FrameTimingTracker::CompositeTimingSet> composite_events,
55 scoped_ptr<FrameTimingTracker::MainFrameTimingSet> main_frame_events) 55 std::unique_ptr<FrameTimingTracker::MainFrameTimingSet> main_frame_events)
56 override; 56 override;
57 void BeginMainFrame( 57 void BeginMainFrame(std::unique_ptr<BeginMainFrameAndCommitState>
58 scoped_ptr<BeginMainFrameAndCommitState> begin_main_frame_state) override; 58 begin_main_frame_state) override;
59 59
60 TestHooks* test_hooks_; 60 TestHooks* test_hooks_;
61 ThreadedChannelForTest* threaded_channel_for_test_; 61 ThreadedChannelForTest* threaded_channel_for_test_;
62 }; 62 };
63 63
64 } // namespace cc 64 } // namespace cc
65 65
66 #endif // CC_TEST_PROXY_MAIN_FOR_TEST_H_ 66 #endif // CC_TEST_PROXY_MAIN_FOR_TEST_H_
OLDNEW
« no previous file with comments | « cc/test/proxy_impl_for_test.cc ('k') | cc/test/proxy_main_for_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698