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 "ui/events/ozone/evdev/event_factory_evdev.h" | 5 #include "ui/events/ozone/evdev/event_factory_evdev.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/task_runner.h" | 8 #include "base/task_runner.h" |
9 #include "base/thread_task_runner_handle.h" | 9 #include "base/thread_task_runner_handle.h" |
10 #include "base/threading/worker_pool.h" | 10 #include "base/threading/worker_pool.h" |
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
318 weak_ptr_factory_.GetWeakPtr())); | 318 weak_ptr_factory_.GetWeakPtr())); |
319 thread_.Start(proxy_dispatcher.Pass(), cursor_, | 319 thread_.Start(proxy_dispatcher.Pass(), cursor_, |
320 base::Bind(&EventFactoryEvdev::OnThreadStarted, | 320 base::Bind(&EventFactoryEvdev::OnThreadStarted, |
321 weak_ptr_factory_.GetWeakPtr())); | 321 weak_ptr_factory_.GetWeakPtr())); |
322 } | 322 } |
323 | 323 |
324 void EventFactoryEvdev::OnThreadStarted( | 324 void EventFactoryEvdev::OnThreadStarted( |
325 scoped_ptr<InputDeviceFactoryEvdevProxy> input_device_factory) { | 325 scoped_ptr<InputDeviceFactoryEvdevProxy> input_device_factory) { |
326 input_device_factory_proxy_ = input_device_factory.Pass(); | 326 input_device_factory_proxy_ = input_device_factory.Pass(); |
327 | 327 |
328 // TODO(spang): This settings interface is really broken. crbug.com/450899 | 328 // Hook up device configuration. |
329 input_controller_.SetInputDeviceFactory(input_device_factory_proxy_.get()); | 329 input_controller_.SetInputDeviceFactory(input_device_factory_proxy_.get()); |
330 | 330 |
331 // Scan & monitor devices. | 331 // Scan & monitor devices. |
332 device_manager_->AddObserver(this); | 332 device_manager_->AddObserver(this); |
333 device_manager_->ScanDevices(this); | 333 device_manager_->ScanDevices(this); |
334 } | 334 } |
335 | 335 |
336 } // namespace ui | 336 } // namespace ui |
OLD | NEW |