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

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

Issue 830593003: Update mojo sdk to rev 9fbbc4f0fef1187312316c0ed992342474e139f1 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: cherry-pick mojo 9d3b8dd17f12d20035a14737fdc38dd926890ff8 Created 5 years, 11 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_LIB_VIEW_PRIVATE_H_ 5 #ifndef MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_PRIVATE_H_
6 #define MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_PRIVATE_H_ 6 #define MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_PRIVATE_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 9
10 #include "mojo/services/view_manager/public/cpp/view.h" 10 #include "view_manager/public/cpp/view.h"
11 11
12 namespace mojo { 12 namespace mojo {
13 13
14 // This class is a friend of a View and contains functions to mutate internal 14 // This class is a friend of a View and contains functions to mutate internal
15 // state of View. 15 // state of View.
16 class ViewPrivate { 16 class ViewPrivate {
17 public: 17 public:
18 explicit ViewPrivate(View* view); 18 explicit ViewPrivate(View* view);
19 ~ViewPrivate(); 19 ~ViewPrivate();
20 20
(...skipping 11 matching lines...) Expand all
32 void set_id(Id id) { view_->id_ = id; } 32 void set_id(Id id) { view_->id_ = id; }
33 33
34 void set_view_manager(ViewManager* manager) { 34 void set_view_manager(ViewManager* manager) {
35 view_->manager_ = manager; 35 view_->manager_ = manager;
36 } 36 }
37 37
38 void set_properties(const std::map<std::string, std::vector<uint8_t>>& data) { 38 void set_properties(const std::map<std::string, std::vector<uint8_t>>& data) {
39 view_->properties_ = data; 39 view_->properties_ = data;
40 } 40 }
41 41
42 void set_viewport_metrics(ViewportMetricsPtr viewport_metrics) {
43 view_->viewport_metrics_ = viewport_metrics.Pass();
44 }
45
42 void LocalDestroy() { 46 void LocalDestroy() {
43 view_->LocalDestroy(); 47 view_->LocalDestroy();
44 } 48 }
45 void LocalAddChild(View* child) { 49 void LocalAddChild(View* child) {
46 view_->LocalAddChild(child); 50 view_->LocalAddChild(child);
47 } 51 }
48 void LocalRemoveChild(View* child) { 52 void LocalRemoveChild(View* child) {
49 view_->LocalRemoveChild(child); 53 view_->LocalRemoveChild(child);
50 } 54 }
51 void LocalReorder(View* relative, OrderDirection direction) { 55 void LocalReorder(View* relative, OrderDirection direction) {
52 view_->LocalReorder(relative, direction); 56 view_->LocalReorder(relative, direction);
53 } 57 }
54 void LocalSetBounds(const Rect& old_bounds, 58 void LocalSetBounds(const Rect& old_bounds,
55 const Rect& new_bounds) { 59 const Rect& new_bounds) {
56 view_->LocalSetBounds(old_bounds, new_bounds); 60 view_->LocalSetBounds(old_bounds, new_bounds);
57 } 61 }
58 void LocalSetDrawn(bool drawn) { view_->LocalSetDrawn(drawn); } 62 void LocalSetDrawn(bool drawn) { view_->LocalSetDrawn(drawn); }
59 63
60 private: 64 private:
61 View* view_; 65 View* view_;
62 66
63 DISALLOW_COPY_AND_ASSIGN(ViewPrivate); 67 DISALLOW_COPY_AND_ASSIGN(ViewPrivate);
64 }; 68 };
65 69
66 } // namespace mojo 70 } // namespace mojo
67 71
68 #endif // MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_PRIVATE_H_ 72 #endif // MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_PRIVATE_H_
OLDNEW
« no previous file with comments | « mojo/services/view_manager/public/cpp/lib/view_observer.cc ('k') | mojo/services/view_manager/public/cpp/lib/view_private.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698