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 "services/ui/public/cpp/window_tree_client.h" | 5 #include "services/ui/public/cpp/window_tree_client.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 #include <utility> | 10 #include <utility> |
(...skipping 657 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
668 // WindowTreeClient, WindowTreeClient implementation: | 668 // WindowTreeClient, WindowTreeClient implementation: |
669 | 669 |
670 void WindowTreeClient::AddObserver(WindowTreeClientObserver* observer) { | 670 void WindowTreeClient::AddObserver(WindowTreeClientObserver* observer) { |
671 observers_.AddObserver(observer); | 671 observers_.AddObserver(observer); |
672 } | 672 } |
673 | 673 |
674 void WindowTreeClient::RemoveObserver(WindowTreeClientObserver* observer) { | 674 void WindowTreeClient::RemoveObserver(WindowTreeClientObserver* observer) { |
675 observers_.RemoveObserver(observer); | 675 observers_.RemoveObserver(observer); |
676 } | 676 } |
677 | 677 |
| 678 void WindowTreeClient::SetAcceptEvents(Id window_id, bool accept_events) { |
| 679 DCHECK(tree_); |
| 680 tree_->SetAcceptEvents(window_id, accept_events); |
| 681 } |
| 682 |
678 void WindowTreeClient::OnEmbed(ClientSpecificId client_id, | 683 void WindowTreeClient::OnEmbed(ClientSpecificId client_id, |
679 mojom::WindowDataPtr root_data, | 684 mojom::WindowDataPtr root_data, |
680 mojom::WindowTreePtr tree, | 685 mojom::WindowTreePtr tree, |
681 int64_t display_id, | 686 int64_t display_id, |
682 Id focused_window_id, | 687 Id focused_window_id, |
683 bool drawn) { | 688 bool drawn) { |
684 DCHECK(!tree_ptr_); | 689 DCHECK(!tree_ptr_); |
685 tree_ptr_ = std::move(tree); | 690 tree_ptr_ = std::move(tree); |
686 tree_ptr_.set_connection_error_handler( | 691 tree_ptr_.set_connection_error_handler( |
687 base::Bind(&DeleteWindowTreeClient, this)); | 692 base::Bind(&DeleteWindowTreeClient, this)); |
(...skipping 487 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1175 Window* window, | 1180 Window* window, |
1176 const gfx::Vector2d& offset, | 1181 const gfx::Vector2d& offset, |
1177 const gfx::Insets& hit_area) { | 1182 const gfx::Insets& hit_area) { |
1178 if (window_manager_internal_client_) { | 1183 if (window_manager_internal_client_) { |
1179 window_manager_internal_client_->SetUnderlaySurfaceOffsetAndExtendedHitArea( | 1184 window_manager_internal_client_->SetUnderlaySurfaceOffsetAndExtendedHitArea( |
1180 server_id(window), offset.x(), offset.y(), hit_area); | 1185 server_id(window), offset.x(), offset.y(), hit_area); |
1181 } | 1186 } |
1182 } | 1187 } |
1183 | 1188 |
1184 } // namespace ui | 1189 } // namespace ui |
OLD | NEW |