| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/ozone/public/event_factory_ozone.h" | 5 #include "ui/ozone/public/event_factory_ozone.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 | 8 |
| 9 namespace ui { | 9 namespace ui { |
| 10 | 10 |
| 11 EventFactoryOzone::IndirectTouchConfiguration::IndirectTouchConfiguration() : s
ensitivity_(0), tap_to_click_(false), three_finger_click_(false), tap_dragging_(
false), natural_scroll_(false) {} |
| 12 |
| 13 EventFactoryOzone::RelXYConfiguration::RelXYConfiguration() : sensitivity_(0),
primary_button_right_(false) {} |
| 14 |
| 11 // static | 15 // static |
| 12 EventFactoryOzone* EventFactoryOzone::impl_ = NULL; | 16 EventFactoryOzone* EventFactoryOzone::impl_ = NULL; |
| 13 | 17 |
| 14 EventFactoryOzone::EventFactoryOzone() { | 18 EventFactoryOzone::EventFactoryOzone() { |
| 15 CHECK(!impl_) << "There should only be a single EventFactoryOzone"; | 19 CHECK(!impl_) << "There should only be a single EventFactoryOzone"; |
| 16 impl_ = this; | 20 impl_ = this; |
| 17 } | 21 } |
| 18 | 22 |
| 19 EventFactoryOzone::~EventFactoryOzone() { | 23 EventFactoryOzone::~EventFactoryOzone() { |
| 20 CHECK_EQ(impl_, this); | 24 CHECK_EQ(impl_, this); |
| 21 impl_ = NULL; | 25 impl_ = NULL; |
| 22 } | 26 } |
| 23 | 27 |
| 24 EventFactoryOzone* EventFactoryOzone::GetInstance() { | 28 EventFactoryOzone* EventFactoryOzone::GetInstance() { |
| 25 CHECK(impl_) << "No EventFactoryOzone implementation set."; | 29 CHECK(impl_) << "No EventFactoryOzone implementation set."; |
| 26 return impl_; | 30 return impl_; |
| 27 } | 31 } |
| 28 | 32 |
| 29 void EventFactoryOzone::WarpCursorTo(gfx::AcceleratedWidget widget, | 33 void EventFactoryOzone::WarpCursorTo(gfx::AcceleratedWidget widget, |
| 30 const gfx::PointF& location) { | 34 const gfx::PointF& location) { |
| 31 NOTIMPLEMENTED(); | 35 NOTIMPLEMENTED(); |
| 32 } | 36 } |
| 33 | 37 |
| 38 bool EventFactoryOzone::HasIndirectTouch() { |
| 39 NOTIMPLEMENTED(); |
| 40 return false; |
| 41 } |
| 42 |
| 43 void EventFactoryOzone::ConfigureIndirectTouchEventConverters(const IndirectTouc
hConfiguration& config, const IndirectTouchConfiguration& mask) { |
| 44 NOTIMPLEMENTED(); |
| 45 } |
| 46 |
| 47 bool EventFactoryOzone::HasRelXY() { |
| 48 NOTIMPLEMENTED(); |
| 49 return false; |
| 50 } |
| 51 |
| 52 void EventFactoryOzone::ConfigureRelXYEventConverters(const RelXYConfiguration&
config, const RelXYConfiguration& mask) { |
| 53 NOTIMPLEMENTED(); |
| 54 } |
| 55 |
| 56 |
| 34 } // namespace ui | 57 } // namespace ui |
| OLD | NEW |