| 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/ozone/platform/dri/cursor_factory_evdev_dri.h" | 5 #include "ui/ozone/platform/dri/cursor_factory_evdev_dri.h" |
| 6 | 6 |
| 7 #include "ui/gfx/geometry/point_conversions.h" | 7 #include "ui/gfx/geometry/point_conversions.h" |
| 8 #include "ui/ozone/platform/dri/dri_surface_factory.h" | 8 #include "ui/ozone/platform/dri/dri_surface_factory.h" |
| 9 #include "ui/ozone/platform/dri/hardware_cursor_delegate.h" | 9 #include "ui/ozone/platform/dri/hardware_cursor_delegate.h" |
| 10 | 10 |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 51 } | 51 } |
| 52 | 52 |
| 53 void CursorFactoryEvdevDri::MoveCursor(const gfx::Vector2dF& delta) { | 53 void CursorFactoryEvdevDri::MoveCursor(const gfx::Vector2dF& delta) { |
| 54 MoveCursorTo(cursor_window_, cursor_location_ + delta); | 54 MoveCursorTo(cursor_window_, cursor_location_ + delta); |
| 55 } | 55 } |
| 56 | 56 |
| 57 gfx::AcceleratedWidget CursorFactoryEvdevDri::GetCursorWindow() { | 57 gfx::AcceleratedWidget CursorFactoryEvdevDri::GetCursorWindow() { |
| 58 return cursor_window_; | 58 return cursor_window_; |
| 59 } | 59 } |
| 60 | 60 |
| 61 bool CursorFactoryEvdevDri::IsCursorVisible() { return cursor_; } |
| 62 |
| 61 gfx::PointF CursorFactoryEvdevDri::location() { return cursor_location_; } | 63 gfx::PointF CursorFactoryEvdevDri::location() { return cursor_location_; } |
| 62 | 64 |
| 63 gfx::Point CursorFactoryEvdevDri::bitmap_location() { | 65 gfx::Point CursorFactoryEvdevDri::bitmap_location() { |
| 64 return gfx::ToFlooredPoint(cursor_location_) - | 66 return gfx::ToFlooredPoint(cursor_location_) - |
| 65 cursor_->hotspot().OffsetFromOrigin(); | 67 cursor_->hotspot().OffsetFromOrigin(); |
| 66 } | 68 } |
| 67 | 69 |
| 68 } // namespace ui | 70 } // namespace ui |
| OLD | NEW |