| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "blimp/client/input/blimp_input_manager.h" | 5 #include "blimp/client/input/blimp_input_manager.h" |
| 6 | 6 |
| 7 #include "base/auto_reset.h" | 7 #include "base/auto_reset.h" |
| 8 #include "base/bind.h" | 8 #include "base/bind.h" |
| 9 #include "base/location.h" | 9 #include "base/location.h" |
| 10 #include "ui/events/blink/blink_event_util.h" | 10 #include "ui/events/blink/blink_event_util.h" |
| 11 #include "ui/events/gesture_detection/gesture_provider_config_helper.h" | 11 #include "ui/events/gesture_detection/gesture_provider_config_helper.h" |
| 12 | 12 |
| 13 namespace blimp { | 13 namespace blimp { |
| 14 namespace client { |
| 14 | 15 |
| 15 scoped_ptr<BlimpInputManager> BlimpInputManager::Create( | 16 scoped_ptr<BlimpInputManager> BlimpInputManager::Create( |
| 16 BlimpInputManagerClient* client, | 17 BlimpInputManagerClient* client, |
| 17 scoped_refptr<base::SingleThreadTaskRunner> main_task_runner, | 18 scoped_refptr<base::SingleThreadTaskRunner> main_task_runner, |
| 18 scoped_refptr<base::SingleThreadTaskRunner> compositor_task_runner, | 19 scoped_refptr<base::SingleThreadTaskRunner> compositor_task_runner, |
| 19 const base::WeakPtr<cc::InputHandler>& input_handler) { | 20 const base::WeakPtr<cc::InputHandler>& input_handler) { |
| 20 return make_scoped_ptr(new BlimpInputManager(client, | 21 return make_scoped_ptr(new BlimpInputManager(client, |
| 21 main_task_runner, | 22 main_task_runner, |
| 22 compositor_task_runner, | 23 compositor_task_runner, |
| 23 input_handler)); | 24 input_handler)); |
| (...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 145 } | 146 } |
| 146 | 147 |
| 147 bool BlimpInputManager::IsMainThread() const { | 148 bool BlimpInputManager::IsMainThread() const { |
| 148 return main_task_runner_->BelongsToCurrentThread(); | 149 return main_task_runner_->BelongsToCurrentThread(); |
| 149 } | 150 } |
| 150 | 151 |
| 151 bool BlimpInputManager::IsCompositorThread() const { | 152 bool BlimpInputManager::IsCompositorThread() const { |
| 152 return compositor_task_runner_->BelongsToCurrentThread(); | 153 return compositor_task_runner_->BelongsToCurrentThread(); |
| 153 } | 154 } |
| 154 | 155 |
| 156 } // namespace client |
| 155 } // namespace blimp | 157 } // namespace blimp |
| OLD | NEW |