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 #include "services/ui/service.h" | 5 #include "services/ui/service.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
186 // Gpu must be running before the PlatformScreen can be initialized. | 186 // Gpu must be running before the PlatformScreen can be initialized. |
187 platform_screen_->Init(); | 187 platform_screen_->Init(); |
188 window_server_.reset( | 188 window_server_.reset( |
189 new ws::WindowServer(this, platform_display_init_params_.surfaces_state)); | 189 new ws::WindowServer(this, platform_display_init_params_.surfaces_state)); |
190 | 190 |
191 // DeviceDataManager must be initialized before TouchController. On non-Linux | 191 // DeviceDataManager must be initialized before TouchController. On non-Linux |
192 // platforms there is no DeviceDataManager so don't create touch controller. | 192 // platforms there is no DeviceDataManager so don't create touch controller. |
193 if (ui::DeviceDataManager::HasInstance()) | 193 if (ui::DeviceDataManager::HasInstance()) |
194 touch_controller_.reset( | 194 touch_controller_.reset( |
195 new ws::TouchController(window_server_->display_manager())); | 195 new ws::TouchController(window_server_->display_manager())); |
| 196 |
| 197 ime_server_.Init(connector()); |
196 } | 198 } |
197 | 199 |
198 bool Service::OnConnect(const shell::Identity& remote_identity, | 200 bool Service::OnConnect(const shell::Identity& remote_identity, |
199 shell::InterfaceRegistry* registry) { | 201 shell::InterfaceRegistry* registry) { |
200 registry->AddInterface<mojom::AccessibilityManager>(this); | 202 registry->AddInterface<mojom::AccessibilityManager>(this); |
201 registry->AddInterface<mojom::Clipboard>(this); | 203 registry->AddInterface<mojom::Clipboard>(this); |
202 registry->AddInterface<mojom::DisplayManager>(this); | 204 registry->AddInterface<mojom::DisplayManager>(this); |
203 registry->AddInterface<mojom::GpuService>(this); | 205 registry->AddInterface<mojom::GpuService>(this); |
204 registry->AddInterface<mojom::IMERegistrar>(this); | 206 registry->AddInterface<mojom::IMERegistrar>(this); |
205 registry->AddInterface<mojom::IMEServer>(this); | 207 registry->AddInterface<mojom::IMEServer>(this); |
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
361 // Display manages its own lifetime. | 363 // Display manages its own lifetime. |
362 ws::Display* host_impl = | 364 ws::Display* host_impl = |
363 new ws::Display(window_server_.get(), platform_display_init_params_); | 365 new ws::Display(window_server_.get(), platform_display_init_params_); |
364 host_impl->Init(nullptr); | 366 host_impl->Init(nullptr); |
365 | 367 |
366 if (touch_controller_) | 368 if (touch_controller_) |
367 touch_controller_->UpdateTouchTransforms(); | 369 touch_controller_->UpdateTouchTransforms(); |
368 } | 370 } |
369 | 371 |
370 } // namespace ui | 372 } // namespace ui |
OLD | NEW |