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

Delay hiding git blame tooltip #22644

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

mgsloan
Copy link
Contributor

@mgsloan mgsloan commented Jan 4, 2025

It's easy to overshoot the bottom of the tooltip when cursoring to a button, such as opening the commit from a blame tooltip. Before this change the tooltip would immediately disappear, and now it sticks around for a bit.

Also:

  • Shares the implementation with elements/text.rs. This will particularly be handy when it makes use of hoverable tooltips.

  • Improves the fix to Tooltip stuck on screen #21657.

    • Now the element will no longer think it has an active tooltip that it registers with the window.

    • It will instead display the next available tooltip, whereas I believe before the next available tooltip would be suppressed.

  • Fixes bug where cx.refresh() wasn't called when text tooltip is hidden due to a mouse down event.

  • Ports over fix in Fix tooltips sometimes continuously displaying when the button is selected #14832 to elements/text.rs

Release Notes:

  • The tooltip for inline git blame now waits a bit before disappearing when the mouse leaves it.

@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Jan 4, 2025
@mgsloan mgsloan force-pushed the delay-hiding-hoverable-tooltips branch from 3dcde67 to c553512 Compare January 4, 2025 07:46
@mgsloan mgsloan force-pushed the delay-hiding-hoverable-tooltips branch 10 times, most recently from 20203a4 to 063e920 Compare January 4, 2025 09:51
It's easy to overshoot the bottom of the tooltip when cursoring to a
button, such as opening the commit from a blame tooltip. Before this
change the tooltip would immediately disappear, and now it sticks
around for a bit.

Also:

* Shares the implementation with `elements/text.rs`. This will
particularly be handy when it makes use of hoverable tooltips. Also
means that it will use the same handling for mouse down / mouse
wheel (it did not handle mouse wheel before).

* Improves the fix to #21657.

    - Now the element will no longer think it has an active tooltip
    that it registers with the window.

    - It will instead display the next available tooltip, whereas
    I believe before the next available tooltip would be suppressed.

* Fixes bug where `cx.refresh()` wasn't called when text tooltip is
hidden due to a mouse down event.

* Ports over fix in #14832 to `elements/text.rs`
@mgsloan mgsloan force-pushed the delay-hiding-hoverable-tooltips branch from 063e920 to 9cb70b2 Compare January 4, 2025 19:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla-signed The user has signed the Contributor License Agreement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant