-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Command palette overlaps the pull-down menus #6847
Comments
I can take a look at implementing this enhancement and provide an update later in the week. |
that sound quite bad, @vince-fugnitto did you notice it as well. Does it mean that for toggle menu items we don't show a proper state anymore in menus? |
I believe I mentioned in person that the menu should be dismissed if the quick-open is triggered. |
Hi there, I've now spent some time looking around the menu and command palette related code. registerCommands(commands: CommandRegistry): void {
commands.registerCommand(quickCommand, {
execute: () => this.quickOpenService.open('>')
}); I'm not sure if modifying the action is actually the best approach here so I've not opened a pull request and thought it best to discuss. This is the change I've made in my fork, which does now close an active menu when opening the command palette. @inject(BrowserMenuBarContribution)
protected readonly browserMenuBarContribution: BrowserMenuBarContribution;
registerCommands(commands: CommandRegistry): void {
commands.registerCommand(quickCommand, {
execute: () => {
if (this.browserMenuBarContribution.menuBar) {
const activeMenu = this.browserMenuBarContribution.menuBar.activeMenu;
if (activeMenu) {
activeMenu.close();
}
}
return this.quickOpenService.open('>');
}
}); Any feedback / pointers would be greatly appreciated. Thanks. |
Fixes: #6847 Signed-off-by: Gareth Whittaker <garethwhittaker@hotmail.com>
Fixes: eclipse-theia#6847 Signed-off-by: Gareth Whittaker <garethwhittaker@hotmail.com>
Description
WE should close the opened pull-down menu when activating the command palette, so they do not overlap.
Reproduction Steps
-Open any pull-down menu (File, Debug, View ...
--> Both popup are open simultaneously
-> After [editor] add misc toggle commands to the view menu #6843, the pulldown menu does not get refresh after selecting some toggling options.
OS and Theia version:
Ubuntu 16.04
Theia: latest master
Chrome
Diagnostics:
The text was updated successfully, but these errors were encountered: