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

Side by Side Diff: services/ui/public/cpp/tests/window_server_test_base.cc

Issue 2183163002: mus: Change PointerWatcher to observe all pointer events, with moves optional. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ifs Created 4 years, 4 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
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 #include "services/ui/public/cpp/tests/window_server_test_base.h" 5 #include "services/ui/public/cpp/tests/window_server_test_base.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/location.h" 8 #include "base/location.h"
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "base/single_thread_task_runner.h" 10 #include "base/single_thread_task_runner.h"
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 most_recent_client_ = root->window_tree(); 82 most_recent_client_ = root->window_tree();
83 EXPECT_TRUE(QuitRunLoop()); 83 EXPECT_TRUE(QuitRunLoop());
84 ASSERT_TRUE(window_manager_client_); 84 ASSERT_TRUE(window_manager_client_);
85 window_manager_client_->AddActivationParent(root); 85 window_manager_client_->AddActivationParent(root);
86 } 86 }
87 87
88 void WindowServerTestBase::OnDidDestroyClient(WindowTreeClient* client) { 88 void WindowServerTestBase::OnDidDestroyClient(WindowTreeClient* client) {
89 window_tree_client_destroyed_ = true; 89 window_tree_client_destroyed_ = true;
90 } 90 }
91 91
92 void WindowServerTestBase::OnEventObserved(const ui::Event& event, 92 void WindowServerTestBase::OnPointerEventObserved(const ui::PointerEvent& event,
93 Window* target) {} 93 Window* target) {}
94 94
95 void WindowServerTestBase::SetWindowManagerClient(WindowManagerClient* client) { 95 void WindowServerTestBase::SetWindowManagerClient(WindowManagerClient* client) {
96 window_manager_client_ = client; 96 window_manager_client_ = client;
97 } 97 }
98 98
99 bool WindowServerTestBase::OnWmSetBounds(Window* window, gfx::Rect* bounds) { 99 bool WindowServerTestBase::OnWmSetBounds(Window* window, gfx::Rect* bounds) {
100 return window_manager_delegate_ 100 return window_manager_delegate_
101 ? window_manager_delegate_->OnWmSetBounds(window, bounds) 101 ? window_manager_delegate_->OnWmSetBounds(window, bounds)
102 : true; 102 : true;
103 } 103 }
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 ? window_manager_delegate_->OnAccelerator(accelerator_id, event) 153 ? window_manager_delegate_->OnAccelerator(accelerator_id, event)
154 : mojom::EventResult::UNHANDLED; 154 : mojom::EventResult::UNHANDLED;
155 } 155 }
156 156
157 void WindowServerTestBase::Create(const shell::Identity& remote_identity, 157 void WindowServerTestBase::Create(const shell::Identity& remote_identity,
158 mojom::WindowTreeClientRequest request) { 158 mojom::WindowTreeClientRequest request) {
159 new WindowTreeClient(this, nullptr, std::move(request)); 159 new WindowTreeClient(this, nullptr, std::move(request));
160 } 160 }
161 161
162 } // namespace ui 162 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698