diff options
author | Kalyan Sriram <coder.kalyan@gmail.com> | 2020-04-23 01:00:06 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-23 10:00:06 +0200 |
commit | 326c8bc818a483bad30f7c2233a8f9e36c73d2c6 (patch) | |
tree | a13a7299669dad7bb3982da595d38504686e09d4 /include/backend/drm | |
parent | 6129a6f93e97680dfe7e983db2ee7671edb5ffbe (diff) |
tinywl: fix geo_box bug in cursor resizing
While trying out the tinywl code, I found that the resize mode was behaving
weirdly ... so I looked into code. Turns out the `begin_interactive` method
stores the cursor position plus the geo_box position; however,
`process_cursor_resize` wasn't taking this into account, causing windows to
jump down in size unexpectedly when resized and lose alignment with the cursor.
To fix this, I simply added a member to the `tinywl_server` struct that stores
the geo_box when the mouse enters grab mode, and I referenced that data in the
resize method. I considered polling for this data every time instead of storing
it in the server struct, but 1) since changes in this value are not relevant
and 2) it could potentially decrease performance (I don't know enough about
wlroots to know how much) I decided to just store it. I can change this if
desired.
Diffstat (limited to 'include/backend/drm')
0 files changed, 0 insertions, 0 deletions