diff options
author | Jay Wang <jaytwang@google.com> | 2021-11-19 17:26:26 +0000 |
---|---|---|
committer | Jay Wang <jaytwang@google.com> | 2021-11-20 00:40:38 +0000 |
commit | 2b80b386c4ed5a1b3240da32080280b0a1ec9cef (patch) | |
tree | 724c88da6281ceb4225f8105bc14e56b0d591464 /include/input | |
parent | 5e6b390919a9786a50f9d5cbd539e9dc53ad78c2 (diff) | |
download | native-2b80b386c4ed5a1b3240da32080280b0a1ec9cef.tar.gz |
Revert "Remove x/y offset from MotionEntry"
Revert submission 16295572
Reason for revert: DroidMonitor-triggered revert due to breakage bug http://b/207128427.
BUG: 207128427
Reverted Changes:
I65c284e5e:Input injection: Assume transformed values are in ...
Ifd359ebb0:Remove x/y offset from MotionEntry
Change-Id: Iab395d41d49db17c0a682bdd6c77fe2aacc004f4
Diffstat (limited to 'include/input')
-rw-r--r-- | include/input/Input.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/include/input/Input.h b/include/input/Input.h index 1c79c4a21c..1e06257591 100644 --- a/include/input/Input.h +++ b/include/input/Input.h @@ -377,6 +377,7 @@ struct PointerCoords { // window scale. The global scale will be applied to TOUCH/TOOL_MAJOR/MINOR // axes, however the window scaling will not. void scale(float globalScale, float windowXScale, float windowYScale); + void applyOffset(float xOffset, float yOffset); void transform(const ui::Transform& transform); @@ -566,7 +567,7 @@ public: inline float getYOffset() const { return mTransform.ty(); } - inline const ui::Transform& getTransform() const { return mTransform; } + inline ui::Transform getTransform() const { return mTransform; } inline float getXPrecision() const { return mXPrecision; } @@ -582,7 +583,7 @@ public: void setCursorPosition(float x, float y); - inline const ui::Transform& getRawTransform() const { return mRawTransform; } + ui::Transform getRawTransform() const { return mRawTransform; } static inline bool isValidCursorPosition(float x, float y) { return !isnan(x) && !isnan(y); } |