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 COMPONENTS_MUS_MUS_APP_H_ | 5 #ifndef COMPONENTS_MUS_MUS_APP_H_ |
6 #define COMPONENTS_MUS_MUS_APP_H_ | 6 #define COMPONENTS_MUS_MUS_APP_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
11 #include <vector> | 11 #include <vector> |
12 | 12 |
13 #include "base/macros.h" | 13 #include "base/macros.h" |
14 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
15 #include "components/mus/public/interfaces/display.mojom.h" | 15 #include "components/mus/public/interfaces/display.mojom.h" |
16 #include "components/mus/public/interfaces/gpu.mojom.h" | 16 #include "components/mus/public/interfaces/gpu.mojom.h" |
17 #include "components/mus/public/interfaces/user_access_manager.mojom.h" | 17 #include "components/mus/public/interfaces/user_access_manager.mojom.h" |
18 #include "components/mus/public/interfaces/window_manager_factory.mojom.h" | 18 #include "components/mus/public/interfaces/window_manager_factory.mojom.h" |
19 #include "components/mus/public/interfaces/window_tree.mojom.h" | 19 #include "components/mus/public/interfaces/window_tree.mojom.h" |
20 #include "components/mus/public/interfaces/window_tree_host.mojom.h" | 20 #include "components/mus/public/interfaces/window_tree_host.mojom.h" |
21 #include "components/mus/ws/connection_manager_delegate.h" | 21 #include "components/mus/ws/connection_manager_delegate.h" |
22 #include "components/mus/ws/platform_display_init_params.h" | 22 #include "components/mus/ws/platform_display_init_params.h" |
23 #include "components/mus/ws/user_id.h" | 23 #include "components/mus/ws/user_id.h" |
24 #include "mojo/services/tracing/public/cpp/tracing_impl.h" | 24 #include "mojo/services/tracing/public/cpp/tracing_impl.h" |
| 25 #include "mojo/shell/public/cpp/application_runner.h" |
25 #include "mojo/shell/public/cpp/interface_factory.h" | 26 #include "mojo/shell/public/cpp/interface_factory.h" |
26 #include "mojo/shell/public/cpp/shell_client.h" | 27 #include "mojo/shell/public/cpp/shell_client.h" |
27 | 28 |
28 namespace mojo { | 29 namespace mojo { |
29 class Connector; | 30 class Connector; |
30 } | 31 } |
31 | 32 |
32 namespace ui { | 33 namespace ui { |
33 class PlatformEventSource; | 34 class PlatformEventSource; |
34 } | 35 } |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
67 // TODO(sky): if we allow removal of user ids then we need to close anything | 68 // TODO(sky): if we allow removal of user ids then we need to close anything |
68 // associated with the user (all incoming pipes...) on removal. | 69 // associated with the user (all incoming pipes...) on removal. |
69 UserState* GetUserState(mojo::Connection* connection); | 70 UserState* GetUserState(mojo::Connection* connection); |
70 | 71 |
71 void AddUserIfNecessary(mojo::Connection* connection); | 72 void AddUserIfNecessary(mojo::Connection* connection); |
72 | 73 |
73 // mojo::ShellClient: | 74 // mojo::ShellClient: |
74 void Initialize(mojo::Connector* connector, const mojo::Identity& identity, | 75 void Initialize(mojo::Connector* connector, const mojo::Identity& identity, |
75 uint32_t id) override; | 76 uint32_t id) override; |
76 bool AcceptConnection(mojo::Connection* connection) override; | 77 bool AcceptConnection(mojo::Connection* connection) override; |
| 78 void ShellConnectionLost() override; |
77 | 79 |
78 // ConnectionManagerDelegate: | 80 // ConnectionManagerDelegate: |
79 void OnFirstDisplayReady() override; | 81 void OnFirstDisplayReady() override; |
80 void OnNoMoreDisplays() override; | 82 void OnNoMoreDisplays() override; |
81 scoped_ptr<ws::WindowTreeBinding> CreateWindowTreeBindingForEmbedAtWindow( | 83 scoped_ptr<ws::WindowTreeBinding> CreateWindowTreeBindingForEmbedAtWindow( |
82 ws::ConnectionManager* connection_manager, | 84 ws::ConnectionManager* connection_manager, |
83 ws::WindowTree* tree, | 85 ws::WindowTree* tree, |
84 mojom::WindowTreeRequest tree_request, | 86 mojom::WindowTreeRequest tree_request, |
85 mojom::WindowTreeClientPtr client) override; | 87 mojom::WindowTreeClientPtr client) override; |
86 void CreateDefaultDisplays() override; | 88 void CreateDefaultDisplays() override; |
(...skipping 29 matching lines...) Expand all Loading... |
116 PendingRequests pending_requests_; | 118 PendingRequests pending_requests_; |
117 | 119 |
118 UserIdToUserState user_id_to_user_state_; | 120 UserIdToUserState user_id_to_user_state_; |
119 | 121 |
120 DISALLOW_COPY_AND_ASSIGN(MandolineUIServicesApp); | 122 DISALLOW_COPY_AND_ASSIGN(MandolineUIServicesApp); |
121 }; | 123 }; |
122 | 124 |
123 } // namespace mus | 125 } // namespace mus |
124 | 126 |
125 #endif // COMPONENTS_MUS_MUS_APP_H_ | 127 #endif // COMPONENTS_MUS_MUS_APP_H_ |
OLD | NEW |