Skip to content

core: Fix cursor not updating in all hover cases#23396

Open
robinmiau wants to merge 4 commits into
ruffle-rs:masterfrom
robinmiau:robinmiau-patch-5
Open

core: Fix cursor not updating in all hover cases#23396
robinmiau wants to merge 4 commits into
ruffle-rs:masterfrom
robinmiau:robinmiau-patch-5

Conversation

@robinmiau
Copy link
Copy Markdown
Contributor

Two cases where the cursor was not updated correctly:

  1. When the mouse was stationary but the hovered object changed (e.g. an animated object moved under the cursor), mouse_cursor() was never called because hover events were skipped. Fixed by re-evaluating the cursor whenever the hovered object changes, regardless of mouse movement.

  2. When moving the mouse within the same interactive object, mouse_cursor() was never called since the hovered object pointer did not change. This caused the cursor to remain stuck, most visibly in TextFields where links should show a hand cursor but did not. Fixed by re-evaluating the cursor on every mouse move over the same object.

Update mouse cursor handling for hover events and object changes.
@kjarosh kjarosh added A-input Area: Input handling T-fix Type: Bug fix (in something that's supposed to work already) labels Apr 5, 2026
@Dinnerbone
Copy link
Copy Markdown
Contributor

Looks like this is failing some tests. I guess it's updating the hovered item when it shouldn't be?

Meanwhile; do you have any content that can test this change?

@Dinnerbone Dinnerbone added the waiting-on-author Waiting on the PR author to make the requested changes label Apr 25, 2026
@robinmiau
Copy link
Copy Markdown
Contributor Author

@Dinnerbone Sorry for the long wait.

Yes, that was the issue. I changed it so stationary mouse hover changes go through the existing rollover path instead, while preserving keyboard-focus hover. The failing tab-ordering tests pass now.

I've only tested it on my website, but it requires registration, so I'm not sure if that's helpful?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-input Area: Input handling T-fix Type: Bug fix (in something that's supposed to work already) waiting-on-author Waiting on the PR author to make the requested changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants