Merge pull request #2845 from edwloef/mouse-area-request-redraw

request redraw on mouse area hover change
This commit is contained in:
Héctor 2025-03-16 17:48:41 +01:00 committed by GitHub
commit 68b992962c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -343,6 +343,10 @@ fn update<Message: Clone, Theme, Renderer>(
state.cursor_position = cursor_position; state.cursor_position = cursor_position;
state.bounds = bounds; state.bounds = bounds;
if widget.interaction.is_some() && state.is_hovered != was_hovered {
shell.request_redraw();
}
match ( match (
widget.on_enter.as_ref(), widget.on_enter.as_ref(),
widget.on_move.as_ref(), widget.on_move.as_ref(),