| 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 SERVICES_WINDOW_MANAGER_WINDOW_MANAGER_APP_H_ | 5 #ifndef SERVICES_WINDOW_MANAGER_WINDOW_MANAGER_APP_H_ |
| 6 #define SERVICES_WINDOW_MANAGER_WINDOW_MANAGER_APP_H_ | 6 #define SERVICES_WINDOW_MANAGER_WINDOW_MANAGER_APP_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 | 9 |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 // instances. | 48 // instances. |
| 49 class WindowManagerApp | 49 class WindowManagerApp |
| 50 : public mojo::ApplicationDelegate, | 50 : public mojo::ApplicationDelegate, |
| 51 public mojo::ViewManagerDelegate, | 51 public mojo::ViewManagerDelegate, |
| 52 public mojo::ViewObserver, | 52 public mojo::ViewObserver, |
| 53 public ui::EventHandler, | 53 public ui::EventHandler, |
| 54 public FocusControllerObserver, | 54 public FocusControllerObserver, |
| 55 public CaptureControllerObserver, | 55 public CaptureControllerObserver, |
| 56 public mojo::InterfaceFactory<mojo::WindowManager>, | 56 public mojo::InterfaceFactory<mojo::WindowManager>, |
| 57 public mojo::InterfaceFactory<mojo::WindowManagerInternal>, | 57 public mojo::InterfaceFactory<mojo::WindowManagerInternal>, |
| 58 public mojo::InterfaceFactory<mojo::NativeViewportEventDispatcher>, |
| 58 public mojo::WindowManagerInternal { | 59 public mojo::WindowManagerInternal { |
| 59 public: | 60 public: |
| 60 WindowManagerApp(ViewManagerDelegate* view_manager_delegate, | 61 WindowManagerApp(ViewManagerDelegate* view_manager_delegate, |
| 61 WindowManagerDelegate* window_manager_delegate); | 62 WindowManagerDelegate* window_manager_delegate); |
| 62 ~WindowManagerApp() override; | 63 ~WindowManagerApp() override; |
| 63 | 64 |
| 64 ViewEventDispatcher* event_dispatcher() { | 65 ViewEventDispatcher* event_dispatcher() { |
| 65 return view_event_dispatcher_.get(); | 66 return view_event_dispatcher_.get(); |
| 66 } | 67 } |
| 67 | 68 |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 | 147 |
| 147 // InterfaceFactory<WindowManagerInternal>: | 148 // InterfaceFactory<WindowManagerInternal>: |
| 148 void Create( | 149 void Create( |
| 149 mojo::ApplicationConnection* connection, | 150 mojo::ApplicationConnection* connection, |
| 150 mojo::InterfaceRequest<mojo::WindowManagerInternal> request) override; | 151 mojo::InterfaceRequest<mojo::WindowManagerInternal> request) override; |
| 151 | 152 |
| 152 // InterfaceFactory<WindowManager>: | 153 // InterfaceFactory<WindowManager>: |
| 153 void Create(mojo::ApplicationConnection* connection, | 154 void Create(mojo::ApplicationConnection* connection, |
| 154 mojo::InterfaceRequest<mojo::WindowManager> request) override; | 155 mojo::InterfaceRequest<mojo::WindowManager> request) override; |
| 155 | 156 |
| 157 // InterfaceFactory<NativeViewportEventDispatcher>: |
| 158 void Create(mojo::ApplicationConnection* connection, |
| 159 mojo::InterfaceRequest<mojo::NativeViewportEventDispatcher> |
| 160 request) override; |
| 161 |
| 156 // WindowManagerInternal: | 162 // WindowManagerInternal: |
| 157 void CreateWindowManagerForViewManagerClient( | 163 void CreateWindowManagerForViewManagerClient( |
| 158 uint16_t connection_id, | 164 uint16_t connection_id, |
| 159 mojo::ScopedMessagePipeHandle window_manager_pipe) override; | 165 mojo::ScopedMessagePipeHandle window_manager_pipe) override; |
| 160 void SetViewManagerClient( | 166 void SetViewManagerClient( |
| 161 mojo::ScopedMessagePipeHandle view_manager_client_request) override; | 167 mojo::ScopedMessagePipeHandle view_manager_client_request) override; |
| 162 | 168 |
| 163 mojo::Shell* shell_; | 169 mojo::Shell* shell_; |
| 164 | 170 |
| 165 mojo::InterfaceFactoryImplWithContext<NativeViewportEventDispatcherImpl, | |
| 166 WindowManagerApp> | |
| 167 native_viewport_event_dispatcher_factory_; | |
| 168 | |
| 169 ViewManagerDelegate* wrapped_view_manager_delegate_; | 171 ViewManagerDelegate* wrapped_view_manager_delegate_; |
| 170 WindowManagerDelegate* window_manager_delegate_; | 172 WindowManagerDelegate* window_manager_delegate_; |
| 171 | 173 |
| 172 mojo::ViewManagerServicePtr view_manager_service_; | 174 mojo::ViewManagerServicePtr view_manager_service_; |
| 173 scoped_ptr<mojo::ViewManagerClientFactory> view_manager_client_factory_; | 175 scoped_ptr<mojo::ViewManagerClientFactory> view_manager_client_factory_; |
| 174 mojo::View* root_; | 176 mojo::View* root_; |
| 175 | 177 |
| 176 scoped_ptr<FocusController> focus_controller_; | 178 scoped_ptr<FocusController> focus_controller_; |
| 177 scoped_ptr<CaptureController> capture_controller_; | 179 scoped_ptr<CaptureController> capture_controller_; |
| 178 | 180 |
| 179 Connections connections_; | 181 Connections connections_; |
| 180 RegisteredViewIdSet registered_view_id_set_; | 182 RegisteredViewIdSet registered_view_id_set_; |
| 181 | 183 |
| 182 mojo::WindowManagerInternalClientPtr window_manager_client_; | 184 mojo::WindowManagerInternalClientPtr window_manager_client_; |
| 183 | 185 |
| 184 ScopedVector<PendingEmbed> pending_embeds_; | 186 ScopedVector<PendingEmbed> pending_embeds_; |
| 185 | 187 |
| 186 scoped_ptr<mojo::ViewManagerClient> view_manager_client_; | 188 scoped_ptr<mojo::ViewManagerClient> view_manager_client_; |
| 187 | 189 |
| 188 scoped_ptr<ViewEventDispatcher> view_event_dispatcher_; | 190 scoped_ptr<ViewEventDispatcher> view_event_dispatcher_; |
| 189 | 191 |
| 190 scoped_ptr<mojo::Binding<WindowManagerInternal>> wm_internal_binding_; | 192 scoped_ptr<mojo::Binding<WindowManagerInternal>> wm_internal_binding_; |
| 191 | 193 |
| 192 DISALLOW_COPY_AND_ASSIGN(WindowManagerApp); | 194 DISALLOW_COPY_AND_ASSIGN(WindowManagerApp); |
| 193 }; | 195 }; |
| 194 | 196 |
| 195 } // namespace window_manager | 197 } // namespace window_manager |
| 196 | 198 |
| 197 #endif // SERVICES_WINDOW_MANAGER_WINDOW_MANAGER_APP_H_ | 199 #endif // SERVICES_WINDOW_MANAGER_WINDOW_MANAGER_APP_H_ |
| OLD | NEW |