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

Side by Side Diff: mojo/services/view_manager/public/cpp/view.h

Issue 1180693002: Update from https://crrev.com/333737 (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: rebased Created 5 years, 6 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_PUBLIC_CPP_VIEW_H_ 5 #ifndef MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_VIEW_H_
6 #define MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_VIEW_H_ 6 #define MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_VIEW_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 175
176 // Returns true if embed is allowed for this node. If embedding is allowed all 176 // Returns true if embed is allowed for this node. If embedding is allowed all
177 // the children are removed. 177 // the children are removed.
178 bool PrepareForEmbed(); 178 bool PrepareForEmbed();
179 179
180 ViewManager* manager_; 180 ViewManager* manager_;
181 Id id_; 181 Id id_;
182 View* parent_; 182 View* parent_;
183 Children children_; 183 Children children_;
184 184
185 ObserverList<ViewObserver> observers_; 185 base::ObserverList<ViewObserver> observers_;
186 186
187 Rect bounds_; 187 Rect bounds_;
188 ViewportMetricsPtr viewport_metrics_; 188 ViewportMetricsPtr viewport_metrics_;
189 189
190 bool visible_; 190 bool visible_;
191 191
192 SharedProperties properties_; 192 SharedProperties properties_;
193 193
194 // Drawn state is derived from the visible state and the parent's visible 194 // Drawn state is derived from the visible state and the parent's visible
195 // state. This field is only used if the view has no parent (eg it's a root). 195 // state. This field is only used if the view has no parent (eg it's a root).
196 bool drawn_; 196 bool drawn_;
197 197
198 // Value struct to keep the name and deallocator for this property. 198 // Value struct to keep the name and deallocator for this property.
199 // Key cannot be used for this purpose because it can be char* or 199 // Key cannot be used for this purpose because it can be char* or
200 // WindowProperty<>. 200 // WindowProperty<>.
201 struct Value { 201 struct Value {
202 const char* name; 202 const char* name;
203 int64_t value; 203 int64_t value;
204 PropertyDeallocator deallocator; 204 PropertyDeallocator deallocator;
205 }; 205 };
206 206
207 std::map<const void*, Value> prop_map_; 207 std::map<const void*, Value> prop_map_;
208 208
209 MOJO_DISALLOW_COPY_AND_ASSIGN(View); 209 MOJO_DISALLOW_COPY_AND_ASSIGN(View);
210 }; 210 };
211 211
212 } // namespace mojo 212 } // namespace mojo
213 213
214 #endif // MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_VIEW_H_ 214 #endif // MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_VIEW_H_
OLDNEW
« no previous file with comments | « mojo/services/view_manager/public/cpp/lib/view_private.h ('k') | mojo/tools/roll/roll_network_service.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698