| 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 "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/interfaces/service_provider/service_provider.mojom.h" | 8 #include "mojo/public/interfaces/service_provider/service_provider.mojom.h" |
| 9 #include "mojo/services/view_manager/view_manager_connection.h" | 9 #include "mojo/services/view_manager/view_manager_connection.h" |
| 10 #include "ui/aura/env.h" | 10 #include "ui/aura/env.h" |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 void RootNodeManager::ProcessNodeViewReplaced(const Node* node, | 120 void RootNodeManager::ProcessNodeViewReplaced(const Node* node, |
| 121 const View* new_view, | 121 const View* new_view, |
| 122 const View* old_view) { | 122 const View* old_view) { |
| 123 for (ConnectionMap::iterator i = connection_map_.begin(); | 123 for (ConnectionMap::iterator i = connection_map_.begin(); |
| 124 i != connection_map_.end(); ++i) { | 124 i != connection_map_.end(); ++i) { |
| 125 i->second->ProcessNodeViewReplaced(node, new_view, old_view, | 125 i->second->ProcessNodeViewReplaced(node, new_view, old_view, |
| 126 IsChangeSource(i->first)); | 126 IsChangeSource(i->first)); |
| 127 } | 127 } |
| 128 } | 128 } |
| 129 | 129 |
| 130 void RootNodeManager::ProcessViewInputEvent(const View* view, |
| 131 const ui::Event* event) { |
| 132 for (ConnectionMap::iterator i = connection_map_.begin(); |
| 133 i != connection_map_.end(); ++i) { |
| 134 i->second->ProcessViewInputEvent(view, event); |
| 135 } |
| 136 } |
| 137 |
| 130 void RootNodeManager::ProcessNodeDeleted(const NodeId& node) { | 138 void RootNodeManager::ProcessNodeDeleted(const NodeId& node) { |
| 131 for (ConnectionMap::iterator i = connection_map_.begin(); | 139 for (ConnectionMap::iterator i = connection_map_.begin(); |
| 132 i != connection_map_.end(); ++i) { | 140 i != connection_map_.end(); ++i) { |
| 133 i->second->ProcessNodeDeleted(node, next_server_change_id_, | 141 i->second->ProcessNodeDeleted(node, next_server_change_id_, |
| 134 IsChangeSource(i->first)); | 142 IsChangeSource(i->first)); |
| 135 } | 143 } |
| 136 } | 144 } |
| 137 | 145 |
| 138 void RootNodeManager::ProcessViewDeleted(const ViewId& view) { | 146 void RootNodeManager::ProcessViewDeleted(const ViewId& view) { |
| 139 for (ConnectionMap::iterator i = connection_map_.begin(); | 147 for (ConnectionMap::iterator i = connection_map_.begin(); |
| (...skipping 25 matching lines...) Expand all Loading... |
| 165 if (!root_view_manager_.in_setup()) | 173 if (!root_view_manager_.in_setup()) |
| 166 ProcessNodeHierarchyChanged(node, new_parent, old_parent); | 174 ProcessNodeHierarchyChanged(node, new_parent, old_parent); |
| 167 } | 175 } |
| 168 | 176 |
| 169 void RootNodeManager::OnNodeViewReplaced(const Node* node, | 177 void RootNodeManager::OnNodeViewReplaced(const Node* node, |
| 170 const View* new_view, | 178 const View* new_view, |
| 171 const View* old_view) { | 179 const View* old_view) { |
| 172 ProcessNodeViewReplaced(node, new_view, old_view); | 180 ProcessNodeViewReplaced(node, new_view, old_view); |
| 173 } | 181 } |
| 174 | 182 |
| 183 void RootNodeManager::OnViewInputEvent(const View* view, |
| 184 const ui::Event* event) { |
| 185 ProcessViewInputEvent(view, event); |
| 186 } |
| 187 |
| 175 } // namespace service | 188 } // namespace service |
| 176 } // namespace view_manager | 189 } // namespace view_manager |
| 177 } // namespace mojo | 190 } // namespace mojo |
| OLD | NEW |