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 #ifndef MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_MANAGER_CLIENT_IMPL_H_ | 5 #ifndef MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_MANAGER_CLIENT_IMPL_H_ |
6 #define MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_MANAGER_CLIENT_IMPL_H_ | 6 #define MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_MANAGER_CLIENT_IMPL_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/memory/scoped_vector.h" | 9 #include "base/memory/scoped_vector.h" |
10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 void SetVisible(Id view_id, bool visible); | 57 void SetVisible(Id view_id, bool visible); |
58 void SetProperty(Id view_id, | 58 void SetProperty(Id view_id, |
59 const std::string& name, | 59 const std::string& name, |
60 const std::vector<uint8_t>& data); | 60 const std::vector<uint8_t>& data); |
61 | 61 |
62 void Embed(const String& url, Id view_id); | 62 void Embed(const String& url, Id view_id); |
63 void Embed(const String& url, | 63 void Embed(const String& url, |
64 Id view_id, | 64 Id view_id, |
65 InterfaceRequest<ServiceProvider> services, | 65 InterfaceRequest<ServiceProvider> services, |
66 ServiceProviderPtr exposed_services); | 66 ServiceProviderPtr exposed_services); |
| 67 void Embed(Id view_id, ViewManagerClientPtr client); |
67 | 68 |
68 void set_change_acked_callback(const base::Callback<void(void)>& callback) { | 69 void set_change_acked_callback(const base::Callback<void(void)>& callback) { |
69 change_acked_callback_ = callback; | 70 change_acked_callback_ = callback; |
70 } | 71 } |
71 void ClearChangeAckedCallback() { | 72 void ClearChangeAckedCallback() { |
72 change_acked_callback_ = base::Callback<void(void)>(); | 73 change_acked_callback_ = base::Callback<void(void)>(); |
73 } | 74 } |
74 | 75 |
75 // Start/stop tracking views. While tracked, they can be retrieved via | 76 // Start/stop tracking views. While tracked, they can be retrieved via |
76 // ViewManager::GetViewById. | 77 // ViewManager::GetViewById. |
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
168 Binding<ViewManagerClient> binding_; | 169 Binding<ViewManagerClient> binding_; |
169 ViewManagerServicePtr service_; | 170 ViewManagerServicePtr service_; |
170 const bool delete_on_error_; | 171 const bool delete_on_error_; |
171 | 172 |
172 DISALLOW_COPY_AND_ASSIGN(ViewManagerClientImpl); | 173 DISALLOW_COPY_AND_ASSIGN(ViewManagerClientImpl); |
173 }; | 174 }; |
174 | 175 |
175 } // namespace mojo | 176 } // namespace mojo |
176 | 177 |
177 #endif // MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_MANAGER_CLIENT_IMPL_H_ | 178 #endif // MOJO_SERVICES_VIEW_MANAGER_PUBLIC_CPP_LIB_VIEW_MANAGER_CLIENT_IMPL_H_ |
OLD | NEW |