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

Side by Side Diff: mojo/services/view_manager/connection_manager.h

Issue 667223002: Mojo: More virtual/override style fixes in mojo/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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
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 #ifndef MOJO_SERVICES_VIEW_MANAGER_CONNECTION_MANAGER_H_ 5 #ifndef MOJO_SERVICES_VIEW_MANAGER_CONNECTION_MANAGER_H_
6 #define MOJO_SERVICES_VIEW_MANAGER_CONNECTION_MANAGER_H_ 6 #define MOJO_SERVICES_VIEW_MANAGER_CONNECTION_MANAGER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 10
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 const bool is_delete_view_; 61 const bool is_delete_view_;
62 62
63 // See description of MarkConnectionAsMessaged/DidMessageConnection. 63 // See description of MarkConnectionAsMessaged/DidMessageConnection.
64 std::set<ConnectionSpecificId> message_ids_; 64 std::set<ConnectionSpecificId> message_ids_;
65 65
66 DISALLOW_COPY_AND_ASSIGN(ScopedChange); 66 DISALLOW_COPY_AND_ASSIGN(ScopedChange);
67 }; 67 };
68 68
69 ConnectionManager(ApplicationConnection* app_connection, 69 ConnectionManager(ApplicationConnection* app_connection,
70 const Callback<void()>& native_viewport_closed_callback); 70 const Callback<void()>& native_viewport_closed_callback);
71 virtual ~ConnectionManager(); 71 ~ConnectionManager() override;
72 72
73 // Returns the id for the next ViewManagerServiceImpl. 73 // Returns the id for the next ViewManagerServiceImpl.
74 ConnectionSpecificId GetAndAdvanceNextConnectionId(); 74 ConnectionSpecificId GetAndAdvanceNextConnectionId();
75 75
76 void AddConnection(ViewManagerServiceImpl* connection); 76 void AddConnection(ViewManagerServiceImpl* connection);
77 void RemoveConnection(ViewManagerServiceImpl* connection); 77 void RemoveConnection(ViewManagerServiceImpl* connection);
78 78
79 // Used in two cases: 79 // Used in two cases:
80 // . Establishes the client for the root. 80 // . Establishes the client for the root.
81 // . Requests to Embed() at an unspecified view. For this case the request 81 // . Requests to Embed() at an unspecified view. For this case the request
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 } 157 }
158 158
159 // Implementation of the two embed variants. 159 // Implementation of the two embed variants.
160 ViewManagerServiceImpl* EmbedImpl( 160 ViewManagerServiceImpl* EmbedImpl(
161 ConnectionSpecificId creator_id, 161 ConnectionSpecificId creator_id,
162 const String& url, 162 const String& url,
163 const ViewId& root_id, 163 const ViewId& root_id,
164 InterfaceRequest<ServiceProvider> service_provider); 164 InterfaceRequest<ServiceProvider> service_provider);
165 165
166 // Overridden from ServerViewDelegate: 166 // Overridden from ServerViewDelegate:
167 virtual void OnViewDestroyed(const ServerView* view) override; 167 void OnViewDestroyed(const ServerView* view) override;
168 virtual void OnWillChangeViewHierarchy(const ServerView* view, 168 void OnWillChangeViewHierarchy(const ServerView* view,
169 const ServerView* new_parent, 169 const ServerView* new_parent,
170 const ServerView* old_parent) override; 170 const ServerView* old_parent) override;
171 virtual void OnViewHierarchyChanged(const ServerView* view, 171 void OnViewHierarchyChanged(const ServerView* view,
172 const ServerView* new_parent, 172 const ServerView* new_parent,
173 const ServerView* old_parent) override; 173 const ServerView* old_parent) override;
174 virtual void OnViewBoundsChanged(const ServerView* view, 174 void OnViewBoundsChanged(const ServerView* view,
175 const gfx::Rect& old_bounds, 175 const gfx::Rect& old_bounds,
176 const gfx::Rect& new_bounds) override; 176 const gfx::Rect& new_bounds) override;
177 virtual void OnViewSurfaceIdChanged(const ServerView* view) override; 177 void OnViewSurfaceIdChanged(const ServerView* view) override;
178 virtual void OnViewReordered(const ServerView* view, 178 void OnViewReordered(const ServerView* view,
179 const ServerView* relative, 179 const ServerView* relative,
180 OrderDirection direction) override; 180 OrderDirection direction) override;
181 virtual void OnWillChangeViewVisibility(const ServerView* view) override; 181 void OnWillChangeViewVisibility(const ServerView* view) override;
182 182
183 ApplicationConnection* app_connection_; 183 ApplicationConnection* app_connection_;
184 184
185 WindowManagerClientImpl wm_client_impl_; 185 WindowManagerClientImpl wm_client_impl_;
186 186
187 // ID to use for next ViewManagerServiceImpl. 187 // ID to use for next ViewManagerServiceImpl.
188 ConnectionSpecificId next_connection_id_; 188 ConnectionSpecificId next_connection_id_;
189 189
190 // Set of ViewManagerServiceImpls. 190 // Set of ViewManagerServiceImpls.
191 ConnectionMap connection_map_; 191 ConnectionMap connection_map_;
(...skipping 10 matching lines...) Expand all
202 // (it's created on the stack by ViewManagerServiceImpl). 202 // (it's created on the stack by ViewManagerServiceImpl).
203 ScopedChange* current_change_; 203 ScopedChange* current_change_;
204 204
205 DISALLOW_COPY_AND_ASSIGN(ConnectionManager); 205 DISALLOW_COPY_AND_ASSIGN(ConnectionManager);
206 }; 206 };
207 207
208 } // namespace service 208 } // namespace service
209 } // namespace mojo 209 } // namespace mojo
210 210
211 #endif // MOJO_SERVICES_VIEW_MANAGER_CONNECTION_MANAGER_H_ 211 #endif // MOJO_SERVICES_VIEW_MANAGER_CONNECTION_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698