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

Context menu triggers preview automatically #46733

Closed
rebornix opened this issue Mar 27, 2018 · 5 comments
Closed

Context menu triggers preview automatically #46733

rebornix opened this issue Mar 27, 2018 · 5 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug search Search widget and operation issues verified Verification succeeded
Milestone

Comments

@rebornix
Copy link
Member

Re #46604

  • Search lifecycle and type lifecycles in replace box
  • Right Click

An editor is opened automatically, it seems weird that we try to show the diff view automatically. Another problem is the diff view rendering seems being blocked as well.

searchcontext

@roblourens roblourens added bug Issue identified by VS Code Team member as probable bug search Search widget and operation issues labels Mar 27, 2018
@roblourens
Copy link
Member

Because we open the file when the item is focused, and all tree context menu contexts are based on which item is focused. So this matches what the problems tree does. Need to find a way to work around it.

@roblourens roblourens added this to the March 2018 milestone Mar 27, 2018
@roblourens
Copy link
Member

I could...

  • Give the TreeResourceNavigator the ability to focus a file without opening it, even when openOnFocus is set on the tree, via the focus payload
  • Right now we only focus the tree here because the active menu items are set with context keys that depend on focus. We could also skip the context keys and return the correct actions by checking element in onContextMenu. Using context keys based on focus for registering menu items seems weird but it seems to be what we do elsewhere.
  • Or, use different context keys that aren't based on focus, but that we just set based on element in onContextMenu. This way onContextMenu wouldn't have to know about particular menu items which is good

@isidor do you know whether we solve this problem anywhere else?

@roblourens roblourens modified the milestones: March 2018, April 2018 Mar 29, 2018
@roblourens
Copy link
Member

Should be @isidorn on the last message, oops :P

@eamodio
Copy link
Contributor

eamodio commented Apr 9, 2018

For the menu part, this might be related too: #22403 (comment)

@isidorn
Copy link
Contributor

isidorn commented Apr 13, 2018

@roblourens this issue does not exist in the explorer becuase when you right click we focus the item
and in the explorer we only open the item on selection.

I see that the search behaves differently (you open on focus change) so you might need a custom solution since we always open on selection in other trees afaik.

roblourens added a commit that referenced this issue Apr 23, 2018
roblourens added a commit that referenced this issue Apr 23, 2018
@sandy081 sandy081 added the verified Verification succeeded label Apr 25, 2018
@vscodebot vscodebot bot locked and limited conversation to collaborators Jun 7, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug search Search widget and operation issues verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

5 participants