Repository navigation
Closed
Labels
Milestone
Description
Tests #3192
- any os - Andre Weinand (@weinand) for OS X
- any os - Kai Maetzel (@kieferrm)
We added a new contribution point called menus which allows extension writers to contribute to different (context) menus. Make sure that
- you get proper intellisense and documentation when authoring
package.json - you get proper validation when authoring
package.json - you get warnings/errors when launching with a bogus menus-contributions
- you get warnings when a menu item references a missing command
- you can contribute an icon to commands in the
commandssection - an icon can be a path or a themable icon which is two values for the light or dark theme
- you can contribute menu items to
editor/title,editor/context, andexplorer/context - a menu item can define a
whencondition under which it shows - the
whenis the same as the keybindings-when and can use the same keys - the
whencan use two new keysresourceSchemeandresourceLangIdwhich are available without an editor - think of the explorer context menu - the
whencan be a boolean configuration value, e.gconfig.editor.lineNumbers - menus update when keys change, e.g.
editorHasSelection - a menu item can declare an alternative command which shows when pressing alt and hovering (not in context menus)
- a menu item can define a
groupwhich is used to group and separate the item from others - there is a special group called
navigationwhich means that the menu item is moved to the top of the context menus or in the title and not overflow area of editor actions - the group can be like
navigation@10where the@10defines the sorting inside that group - the command is passed the URI of the selected resource - the file from the explorer or the document uri from the editor
Reacted by Thaina
Activity
prog110 commentedon Jan 15, 2017
Johannes Rieken (@jrieken) Is there a way currently to contribute commands to exclusively to explorer context menu & add a shortcut for it.
For eg., if I select a folder in explorer & press
alt+insert, I want to add the ability for the user to select a set of options the way intellij show.