OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CONTENT_CHILD_CHILD_THREAD_IMPL_H_ | 5 #ifndef CONTENT_CHILD_CHILD_THREAD_IMPL_H_ |
6 #define CONTENT_CHILD_CHILD_THREAD_IMPL_H_ | 6 #define CONTENT_CHILD_CHILD_THREAD_IMPL_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 | 188 |
189 // Returns the one child thread. Can only be called on the main thread. | 189 // Returns the one child thread. Can only be called on the main thread. |
190 static ChildThreadImpl* current(); | 190 static ChildThreadImpl* current(); |
191 | 191 |
192 #if defined(OS_ANDROID) | 192 #if defined(OS_ANDROID) |
193 // Called on Android's service thread to shutdown the main thread of this | 193 // Called on Android's service thread to shutdown the main thread of this |
194 // process. | 194 // process. |
195 static void ShutdownThread(); | 195 static void ShutdownThread(); |
196 #endif | 196 #endif |
197 | 197 |
198 ServiceRegistry* service_registry() const { | 198 shell::InterfaceRegistry* interface_registry() { |
199 return mojo_application_->service_registry(); | 199 return mojo_application_->interface_registry(); |
| 200 } |
| 201 |
| 202 shell::InterfaceProvider* remote_interfaces() const { |
| 203 return mojo_application_->remote_interfaces(); |
200 } | 204 } |
201 | 205 |
202 protected: | 206 protected: |
203 friend class ChildProcess; | 207 friend class ChildProcess; |
204 | 208 |
205 // Called when the process refcount is 0. | 209 // Called when the process refcount is 0. |
206 void OnProcessFinalRelease(); | 210 void OnProcessFinalRelease(); |
207 | 211 |
208 virtual bool OnControlMessageReceived(const IPC::Message& msg); | 212 virtual bool OnControlMessageReceived(const IPC::Message& msg); |
209 virtual void OnProcessBackgrounded(bool backgrounded); | 213 virtual void OnProcessBackgrounded(bool backgrounded); |
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
338 | 342 |
339 private: | 343 private: |
340 struct Options options_; | 344 struct Options options_; |
341 | 345 |
342 DISALLOW_COPY_AND_ASSIGN(Builder); | 346 DISALLOW_COPY_AND_ASSIGN(Builder); |
343 }; | 347 }; |
344 | 348 |
345 } // namespace content | 349 } // namespace content |
346 | 350 |
347 #endif // CONTENT_CHILD_CHILD_THREAD_IMPL_H_ | 351 #endif // CONTENT_CHILD_CHILD_THREAD_IMPL_H_ |
OLD | NEW |