diff options
Diffstat (limited to 'include/input')
| -rw-r--r-- | include/input/Input.h | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/include/input/Input.h b/include/input/Input.h index a84dcfc63c..027e4a5bdc 100644 --- a/include/input/Input.h +++ b/include/input/Input.h @@ -662,10 +662,6 @@ public: inline void setActionButton(int32_t button) { mActionButton = button; } - inline float getXOffset() const { return mTransform.tx(); } - - inline float getYOffset() const { return mTransform.ty(); } - inline const ui::Transform& getTransform() const { return mTransform; } std::optional<ui::Rotation> getSurfaceRotation() const; @@ -876,6 +872,22 @@ public: void offsetLocation(float xOffset, float yOffset); + /** + * Get the X offset of this motion event relative to the origin of the raw coordinate space. + * + * In practice, this is the delta that was added to the raw screen coordinates (i.e. in logical + * display space) to adjust for the absolute position of the containing windows and views. + */ + float getRawXOffset() const; + + /** + * Get the Y offset of this motion event relative to the origin of the raw coordinate space. + * + * In practice, this is the delta that was added to the raw screen coordinates (i.e. in logical + * display space) to adjust for the absolute position of the containing windows and views. + */ + float getRawYOffset() const; + void scale(float globalScaleFactor); // Set 3x3 perspective matrix transformation. |