OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #include "services/ui/ws/test_utils.h" | 5 #include "services/ui/ws/test_utils.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/memory/ptr_util.h" | 9 #include "base/memory/ptr_util.h" |
10 #include "cc/output/copy_output_request.h" | 10 #include "cc/output/copy_output_request.h" |
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 TestPlatformDisplayFactory::~TestPlatformDisplayFactory() {} | 144 TestPlatformDisplayFactory::~TestPlatformDisplayFactory() {} |
145 | 145 |
146 std::unique_ptr<PlatformDisplay> | 146 std::unique_ptr<PlatformDisplay> |
147 TestPlatformDisplayFactory::CreatePlatformDisplay( | 147 TestPlatformDisplayFactory::CreatePlatformDisplay( |
148 const PlatformDisplayInitParams& init_params) { | 148 const PlatformDisplayInitParams& init_params) { |
149 return base::MakeUnique<TestPlatformDisplay>(init_params, cursor_storage_); | 149 return base::MakeUnique<TestPlatformDisplay>(init_params, cursor_storage_); |
150 } | 150 } |
151 | 151 |
152 // TestFrameGeneratorDelegate ------------------------------------------------- | 152 // TestFrameGeneratorDelegate ------------------------------------------------- |
153 | 153 |
154 TestFrameGeneratorDelegate::TestFrameGeneratorDelegate() {} | 154 TestFrameGeneratorDelegate::TestFrameGeneratorDelegate( |
| 155 ServerWindow* root_window) |
| 156 : root_window_(root_window) {} |
155 | 157 |
156 TestFrameGeneratorDelegate::~TestFrameGeneratorDelegate() {} | 158 TestFrameGeneratorDelegate::~TestFrameGeneratorDelegate() {} |
157 | 159 |
| 160 ServerWindow* TestFrameGeneratorDelegate::GetActiveRootWindow() { |
| 161 return root_window_; |
| 162 } |
| 163 |
158 bool TestFrameGeneratorDelegate::IsInHighContrastMode() { | 164 bool TestFrameGeneratorDelegate::IsInHighContrastMode() { |
159 return false; | 165 return false; |
160 } | 166 } |
161 | 167 |
162 // WindowTreeTestApi --------------------------------------------------------- | 168 // WindowTreeTestApi --------------------------------------------------------- |
163 | 169 |
164 WindowTreeTestApi::WindowTreeTestApi(WindowTree* tree) : tree_(tree) {} | 170 WindowTreeTestApi::WindowTreeTestApi(WindowTree* tree) : tree_(tree) {} |
165 WindowTreeTestApi::~WindowTreeTestApi() {} | 171 WindowTreeTestApi::~WindowTreeTestApi() {} |
166 | 172 |
167 void WindowTreeTestApi::StartPointerWatcher(bool want_moves) { | 173 void WindowTreeTestApi::StartPointerWatcher(bool want_moves) { |
(...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
622 return nullptr; | 628 return nullptr; |
623 if (!tree->AddWindow(parent_client_id, client_window_id)) | 629 if (!tree->AddWindow(parent_client_id, client_window_id)) |
624 return nullptr; | 630 return nullptr; |
625 *client_id = client_window_id; | 631 *client_id = client_window_id; |
626 return tree->GetWindowByClientId(client_window_id); | 632 return tree->GetWindowByClientId(client_window_id); |
627 } | 633 } |
628 | 634 |
629 } // namespace test | 635 } // namespace test |
630 } // namespace ws | 636 } // namespace ws |
631 } // namespace ui | 637 } // namespace ui |
OLD | NEW |