Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Fix: Round up deltas for smooth scrolling, so that target will eventually be reached #7040
When smooth scrolling is enabled, the original code rounds the deltas toward zero. This means that the scroll position will never actually reach the destination scroll position (when the difference is 3, there will be no more scrolling in the original code). Rounding away from zero fixes this problem.
This bug also causes the cargo flow legend overlay to not be redrawn when smooth scrolling is enabled, because variable
To observe the bug in the original code: