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

Side by Side Diff: mojo/services/view_manager/root_node_manager.cc

Issue 507563002: Removes usage of aura::Window from Node (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review Created 6 years, 3 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 | Annotate | Revision Log
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 "mojo/services/view_manager/root_node_manager.h" 5 #include "mojo/services/view_manager/root_node_manager.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "mojo/public/cpp/application/application_connection.h" 8 #include "mojo/public/cpp/application/application_connection.h"
9 #include "mojo/public/interfaces/application/service_provider.mojom.h" 9 #include "mojo/public/interfaces/application/service_provider.mojom.h"
10 #include "mojo/services/public/cpp/input_events/input_events_type_converters.h" 10 #include "mojo/services/public/cpp/input_events/input_events_type_converters.h"
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 const Node* new_parent, 245 const Node* new_parent,
246 const Node* old_parent) { 246 const Node* old_parent) {
247 if (!root_view_manager_.in_setup()) 247 if (!root_view_manager_.in_setup())
248 ProcessNodeHierarchyChanged(node, new_parent, old_parent); 248 ProcessNodeHierarchyChanged(node, new_parent, old_parent);
249 } 249 }
250 250
251 void RootNodeManager::OnNodeBoundsChanged(const Node* node, 251 void RootNodeManager::OnNodeBoundsChanged(const Node* node,
252 const gfx::Rect& old_bounds, 252 const gfx::Rect& old_bounds,
253 const gfx::Rect& new_bounds) { 253 const gfx::Rect& new_bounds) {
254 ProcessNodeBoundsChanged(node, old_bounds, new_bounds); 254 ProcessNodeBoundsChanged(node, old_bounds, new_bounds);
255 if (!node->parent())
256 return;
257
258 // TODO(sky): optimize this.
259 root_view_manager_.SchedulePaint(node->parent(), old_bounds);
260 root_view_manager_.SchedulePaint(node->parent(), new_bounds);
261 }
262
263 void RootNodeManager::OnNodeBitmapChanged(const Node* node) {
264 root_view_manager_.SchedulePaint(node, gfx::Rect(node->bounds().size()));
255 } 265 }
256 266
257 } // namespace service 267 } // namespace service
258 } // namespace mojo 268 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/services/view_manager/root_node_manager.h ('k') | mojo/services/view_manager/root_view_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698