Fix cursor not updated after clicking internal link
requested to merge davidhurka/okular:fix-cursor-not-updated-after-animated-scroll into release/20.08
updateCursor() was called by wheelEvent(), which made sense, because after the wheel event the page will have moved under the cursor.
With smooth scrolling, it makes less sense in wheelEvent(), because at that point scrolling is still in the future.
scrollContentsBy() appears to be called on every scroll step. (It is documented to be called at scrollbar value changes, so makes sense.)
This patch removes updateCursor() from wheelEvent(), but adds it to scrollContentsBy().
I did not check anything out with d->visibleItems, as was indicated it !176 (merged).
Steps to reproduce
- Open a document with many internal links
- Point the cursor on such a link
- Do a scroll click (like
xdotool click 5
) - Page scrolls, but cursor stays a pointing hand.
- Click on a link and don’t move the cursor.
- Page scrolls, but cursor stays a pointing hand.
Edited by Laura David Hurka