| 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 "base/bind.h" | 5 #include "base/bind.h" |
| 6 #include "base/location.h" | 6 #include "base/location.h" |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "base/single_thread_task_runner.h" | 9 #include "base/single_thread_task_runner.h" |
| 10 #include "base/threading/thread_task_runner_handle.h" | 10 #include "base/threading/thread_task_runner_handle.h" |
| (...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 166 PostMouseEvent(ui::ET_MOUSE_RELEASED, host_location, | 166 PostMouseEvent(ui::ET_MOUSE_RELEASED, host_location, |
| 167 button_down_mask_ | flag, flag); | 167 button_down_mask_ | flag, flag); |
| 168 } | 168 } |
| 169 | 169 |
| 170 RunClosureAfterAllPendingUIEvents(closure); | 170 RunClosureAfterAllPendingUIEvents(closure); |
| 171 return true; | 171 return true; |
| 172 } | 172 } |
| 173 bool SendMouseClick(ui_controls::MouseButton type) override { | 173 bool SendMouseClick(ui_controls::MouseButton type) override { |
| 174 return SendMouseEvents(type, ui_controls::UP | ui_controls::DOWN); | 174 return SendMouseEvents(type, ui_controls::UP | ui_controls::DOWN); |
| 175 } | 175 } |
| 176 bool SendTouchEvents(int action, int num, int x, int y) override { |
| 177 NOTIMPLEMENTED(); |
| 178 return false; |
| 179 } |
| 176 void RunClosureAfterAllPendingUIEvents( | 180 void RunClosureAfterAllPendingUIEvents( |
| 177 const base::Closure& closure) override { | 181 const base::Closure& closure) override { |
| 178 if (!closure.is_null()) | 182 if (!closure.is_null()) |
| 179 base::ThreadTaskRunnerHandle::Get()->PostTask(FROM_HERE, closure); | 183 base::ThreadTaskRunnerHandle::Get()->PostTask(FROM_HERE, closure); |
| 180 } | 184 } |
| 181 | 185 |
| 182 private: | 186 private: |
| 183 void SendEventToSink(ui::Event* event) { | 187 void SendEventToSink(ui::Event* event) { |
| 184 ui::EventSourceTestApi event_source_test(host_->GetEventSource()); | 188 ui::EventSourceTestApi event_source_test(host_->GetEventSource()); |
| 185 ui::EventDispatchDetails details = event_source_test.SendEventToSink(event); | 189 ui::EventDispatchDetails details = event_source_test.SendEventToSink(event); |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 236 }; | 240 }; |
| 237 | 241 |
| 238 } // namespace | 242 } // namespace |
| 239 | 243 |
| 240 ui_controls::UIControlsAura* CreateUIControlsAura(WindowTreeHost* host) { | 244 ui_controls::UIControlsAura* CreateUIControlsAura(WindowTreeHost* host) { |
| 241 return new UIControlsOzone(host); | 245 return new UIControlsOzone(host); |
| 242 } | 246 } |
| 243 | 247 |
| 244 } // namespace test | 248 } // namespace test |
| 245 } // namespace aura | 249 } // namespace aura |
| OLD | NEW |