Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redraw window at regular intervals not a fixed time after last move #249

Merged
merged 1 commit into from
Apr 27, 2024

Conversation

yourealwaysbe
Copy link
Contributor

I noticed that with fractional scaling on Wayland scrolling with the trackpad became very laggy. This pull request fixes that. Hopefully in a reasonable way.

Previously, each redraw would start a timer before the update took place. Each time a new event came, the timer would be reset. This means the update can be indefinitely delayed by a long sequence of events.

Instead, only set the timer if it doesn't exist, so an update is guaranteed to happen at regular intervals, rather than waiting for a pause in the event stream.

Previously, each redraw would start a timer before the update took
place. Each time a new event came, the timer would be reset. This means
the update can be indefinitely delayed by a long sequence of events.

Instead, only set the timer if it doesn't exist, so an update is
guaranteed to happen at regular intervals, rather than waiting for a
pause in the event stream.

This avoids lags, e.g. when fractional scaling is used on Wayland.
@rnorris rnorris merged commit b62b11d into viking-gps:master Apr 27, 2024
20 checks passed
@rnorris
Copy link
Collaborator

rnorris commented Apr 27, 2024

Apologies for the delay, I thought I had done something with this one!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants