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

Side by Side Diff: services/ui/ws/window_tree.cc

Issue 2161993002: Start using display.mojom.Display in mus+ash. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@display_traits
Patch Set: Fixes. Created 4 years, 5 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 | « services/ui/ws/window_server_delegate.h ('k') | services/ui/ws/window_tree_client_unittest.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 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/ws/window_tree.h" 5 #include "services/ui/ws/window_tree.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 DCHECK(window_manager_internal_); 174 DCHECK(window_manager_internal_);
175 const ClientWindowId client_window_id(WindowIdToTransportId(root->id())); 175 const ClientWindowId client_window_id(WindowIdToTransportId(root->id()));
176 DCHECK_EQ(0u, client_id_to_window_id_map_.count(client_window_id)); 176 DCHECK_EQ(0u, client_id_to_window_id_map_.count(client_window_id));
177 client_id_to_window_id_map_[client_window_id] = root->id(); 177 client_id_to_window_id_map_[client_window_id] = root->id();
178 window_id_to_client_id_map_[root->id()] = client_window_id; 178 window_id_to_client_id_map_[root->id()] = client_window_id;
179 roots_.insert(root); 179 roots_.insert(root);
180 180
181 Display* display = GetDisplay(root); 181 Display* display = GetDisplay(root);
182 DCHECK(display); 182 DCHECK(display);
183 183
184 window_manager_internal_->WmNewDisplayAdded(display->ToMojomDisplay(), 184 window_manager_internal_->WmNewDisplayAdded(display->ToDisplay(),
185 WindowToWindowData(root), 185 WindowToWindowData(root),
186 root->parent()->IsDrawn()); 186 root->parent()->IsDrawn());
187 } 187 }
188 188
189 void WindowTree::OnWindowDestroyingTreeImpl(WindowTree* tree) { 189 void WindowTree::OnWindowDestroyingTreeImpl(WindowTree* tree) {
190 if (window_manager_state_) 190 if (window_manager_state_)
191 window_manager_state_->OnWillDestroyTree(tree); 191 window_manager_state_->OnWillDestroyTree(tree);
192 192
193 if (event_source_wms_ && event_source_wms_->window_tree() == tree) 193 if (event_source_wms_ && event_source_wms_->window_tree() == tree)
194 event_source_wms_ = nullptr; 194 event_source_wms_ = nullptr;
(...skipping 1466 matching lines...) Expand 10 before | Expand all | Expand 10 after
1661 } 1661 }
1662 1662
1663 bool WindowTree::IsWindowRootOfAnotherTreeForAccessPolicy( 1663 bool WindowTree::IsWindowRootOfAnotherTreeForAccessPolicy(
1664 const ServerWindow* window) const { 1664 const ServerWindow* window) const {
1665 WindowTree* tree = window_server_->GetTreeWithRoot(window); 1665 WindowTree* tree = window_server_->GetTreeWithRoot(window);
1666 return tree && tree != this; 1666 return tree && tree != this;
1667 } 1667 }
1668 1668
1669 } // namespace ws 1669 } // namespace ws
1670 } // namespace ui 1670 } // namespace ui
OLDNEW
« no previous file with comments | « services/ui/ws/window_server_delegate.h ('k') | services/ui/ws/window_tree_client_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698