| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <stdint.h> | 5 #include <stdint.h> |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 439 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 450 window_tree_host_->OnEvent(event); | 450 window_tree_host_->OnEvent(event); |
| 451 } | 451 } |
| 452 | 452 |
| 453 void set_window_manager_internal(WindowTreeImpl* connection, | 453 void set_window_manager_internal(WindowTreeImpl* connection, |
| 454 mojom::WindowManager* wm_internal) { | 454 mojom::WindowManager* wm_internal) { |
| 455 connection->window_manager_internal_ = wm_internal; | 455 connection->window_manager_internal_ = wm_internal; |
| 456 } | 456 } |
| 457 | 457 |
| 458 void AckPreviousEvent() { | 458 void AckPreviousEvent() { |
| 459 while (window_tree_host_->tree_awaiting_input_ack_) | 459 while (window_tree_host_->tree_awaiting_input_ack_) |
| 460 window_tree_host_->tree_awaiting_input_ack_->OnWindowInputEventAck(0); | 460 window_tree_host_->tree_awaiting_input_ack_->OnWindowInputEventAck(0, |
| 461 true); |
| 461 } | 462 } |
| 462 | 463 |
| 463 void DispatchEventAndAckImmediately(const ui::Event& event) { | 464 void DispatchEventAndAckImmediately(const ui::Event& event) { |
| 464 DispatchEventWithoutAck(event); | 465 DispatchEventWithoutAck(event); |
| 465 AckPreviousEvent(); | 466 AckPreviousEvent(); |
| 466 } | 467 } |
| 467 | 468 |
| 468 // Creates a new window from wm_connection() and embeds a new connection in | 469 // Creates a new window from wm_connection() and embeds a new connection in |
| 469 // it. | 470 // it. |
| 470 void SetupEventTargeting(TestWindowTreeClient** out_client, | 471 void SetupEventTargeting(TestWindowTreeClient** out_client, |
| (...skipping 469 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 940 mojom_window_tree->ReleaseCapture(++change_id, | 941 mojom_window_tree->ReleaseCapture(++change_id, |
| 941 WindowIdToTransportId(root_window->id())); | 942 WindowIdToTransportId(root_window->id())); |
| 942 EXPECT_EQ(window, host->GetCaptureWindow()); | 943 EXPECT_EQ(window, host->GetCaptureWindow()); |
| 943 mojom_window_tree->ReleaseCapture(++change_id, | 944 mojom_window_tree->ReleaseCapture(++change_id, |
| 944 WindowIdToTransportId(window->id())); | 945 WindowIdToTransportId(window->id())); |
| 945 EXPECT_EQ(nullptr, host->GetCaptureWindow()); | 946 EXPECT_EQ(nullptr, host->GetCaptureWindow()); |
| 946 } | 947 } |
| 947 | 948 |
| 948 } // namespace ws | 949 } // namespace ws |
| 949 } // namespace mus | 950 } // namespace mus |
| OLD | NEW |