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 SHELL_APP_CHILD_PROCESS_HOST_H_ | 5 #ifndef SHELL_APP_CHILD_PROCESS_HOST_H_ |
6 #define SHELL_APP_CHILD_PROCESS_HOST_H_ | 6 #define SHELL_APP_CHILD_PROCESS_HOST_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "mojo/edk/embedder/channel_info_forward.h" | 11 #include "mojo/edk/embedder/channel_info_forward.h" |
12 #include "shell/app_child_process.mojom.h" | 12 #include "shell/app_child_process.mojom.h" |
13 #include "shell/child_process_host.h" | 13 #include "shell/child_process_host.h" |
14 | 14 |
15 namespace mojo { | 15 namespace mojo { |
16 namespace shell { | 16 namespace shell { |
17 | 17 |
18 // A subclass of |ChildProcessHost| to host a |TYPE_APP| child process, which | 18 // A subclass of |ChildProcessHost| to host an app child process, which runs a |
19 // runs a single app (loaded from the file system). | 19 // single app (loaded from the file system). |
20 // | 20 // |
21 // Note: After |Start()|, |StartApp| must be called and this object must | 21 // Note: After |Start()|, |StartApp| must be called and this object must |
22 // remained alive until the |on_app_complete| callback is called. | 22 // remained alive until the |on_app_complete| callback is called. |
23 class AppChildProcessHost : public ChildProcessHost, | 23 class AppChildProcessHost : public ChildProcessHost, |
24 public ChildProcessHost::Delegate { | 24 public ChildProcessHost::Delegate { |
25 public: | 25 public: |
26 explicit AppChildProcessHost(Context* context); | 26 explicit AppChildProcessHost(Context* context); |
27 ~AppChildProcessHost() override; | 27 ~AppChildProcessHost() override; |
28 | 28 |
29 // See |AppChildController|: | 29 // See |AppChildController|: |
(...skipping 17 matching lines...) Expand all Loading... |
47 embedder::ChannelInfo* channel_info_; | 47 embedder::ChannelInfo* channel_info_; |
48 AppChildController::StartAppCallback on_app_complete_; | 48 AppChildController::StartAppCallback on_app_complete_; |
49 | 49 |
50 DISALLOW_COPY_AND_ASSIGN(AppChildProcessHost); | 50 DISALLOW_COPY_AND_ASSIGN(AppChildProcessHost); |
51 }; | 51 }; |
52 | 52 |
53 } // namespace shell | 53 } // namespace shell |
54 } // namespace mojo | 54 } // namespace mojo |
55 | 55 |
56 #endif // SHELL_APP_CHILD_PROCESS_HOST_H_ | 56 #endif // SHELL_APP_CHILD_PROCESS_HOST_H_ |
OLD | NEW |