Skip to content

git_ui: Fix tooltip overlaying context menu in git blame#42764

Merged
MrSubidubi merged 4 commits intozed-industries:mainfrom
amustaque97:fix-26949-git-blame-ctx-menu
Dec 8, 2025
Merged

git_ui: Fix tooltip overlaying context menu in git blame#42764
MrSubidubi merged 4 commits intozed-industries:mainfrom
amustaque97:fix-26949-git-blame-ctx-menu

Conversation

@amustaque97
Copy link
Contributor

@amustaque97 amustaque97 commented Nov 14, 2025

Closes #26949

Summary

  1. Split editor references to avoid borrow conflicts in event handlers
  2. Check has_mouse_context_menu() state directly in tooltip conditional instead of caching stale value
  3. Restructured context menu deployment to ensure proper sequencing: hide popover → build menu → deploy menu → notify for re-render

Screen recording

Screen.Recording.2025-12-03.at.6.39.19.PM.mov

Release Notes:

  • Fixed an issue where the context menu in the Git Blame view would be frequently overlapped by the commit information tooltip.

@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Nov 14, 2025
Copy link
Member

@MrSubidubi MrSubidubi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this.

While this is definitely an approach to fix this, this effectively eliminates the ability to have tooltips in deferred draws, does it not? So I doubt this is the proper fix for this.

Additionally, it seems the tooltip can get both stale and annoying, especially once the context menu is deployed. Feels like the approach in the other PR might be more sensible to approach?

@esthertrapadoux
Copy link

@amustaque97 hi! We have a few pairing sessions still available this week if you want to chat with the team and work through some of the feedback above: https://cal.com/esther-trapadoux-zed/30min

@amustaque97 amustaque97 force-pushed the fix-26949-git-blame-ctx-menu branch from 8c77592 to 831dc98 Compare December 3, 2025 13:05
Co-authored-by: Finn Evers <finn.evers@outlook.de>
amustaque97 and others added 2 commits December 3, 2025 23:42
Co-authored-by: Finn Evers <finn.evers@outlook.de>
@MrSubidubi MrSubidubi changed the title git_ui: Context menu behind tooltip in git blame git_ui: Fix tooltip overlaying context menu in git blame Dec 8, 2025
Copy link
Member

@MrSubidubi MrSubidubi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, this looks very good now. Thank you!

@MrSubidubi MrSubidubi enabled auto-merge (squash) December 8, 2025 13:31
@MrSubidubi MrSubidubi merged commit 00e6cbc into zed-industries:main Dec 8, 2025
25 checks passed
@esthertrapadoux esthertrapadoux moved this from Community PRs to Shipped by Community in Quality Week – December 2025 Dec 8, 2025
@esthertrapadoux esthertrapadoux moved this to 🚢 Shipped by Community in Git board Dec 8, 2025
@amustaque97 amustaque97 deleted the fix-26949-git-blame-ctx-menu branch December 8, 2025 16:48
CherryWorm pushed a commit to CherryWorm/zed that referenced this pull request Dec 16, 2025
…ies#42764)

Closes zed-industries#26949


## Summary

1. Split editor references to avoid borrow conflicts in event handlers
2. Check
[has_mouse_context_menu()](vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/code/electron-browser/workbench/workbench.html)
state directly in tooltip conditional instead of caching stale value
3. Restructured context menu deployment to ensure proper sequencing:
hide popover → build menu → deploy menu → notify for re-render

**Screen recording**



https://github.com/user-attachments/assets/8a00f882-1c54-47b0-9211-4f28f8deb867



Release Notes:

- Fixed an issue where the context menu in the Git Blame view would be
frequently overlapped by the commit information tooltip.

---------

Co-authored-by: Finn Evers <finn.evers@outlook.de>
someone13574 pushed a commit to someone13574/zed that referenced this pull request Dec 16, 2025
…ies#42764)

Closes zed-industries#26949


## Summary

1. Split editor references to avoid borrow conflicts in event handlers
2. Check
[has_mouse_context_menu()](vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/code/electron-browser/workbench/workbench.html)
state directly in tooltip conditional instead of caching stale value
3. Restructured context menu deployment to ensure proper sequencing:
hide popover → build menu → deploy menu → notify for re-render

**Screen recording**



https://github.com/user-attachments/assets/8a00f882-1c54-47b0-9211-4f28f8deb867



Release Notes:

- Fixed an issue where the context menu in the Git Blame view would be
frequently overlapped by the commit information tooltip.

---------

Co-authored-by: Finn Evers <finn.evers@outlook.de>
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

Status: 🚢 Shipped by Community

Development

Successfully merging this pull request may close these issues.

Can't use right-click menu in Git blame

5 participants