mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
Allow editor events to close context menu
This commit is contained in:
parent
03f758720c
commit
21d3261eec
@ -198,6 +198,11 @@ RED.contextMenu = (function() {
|
|||||||
}
|
}
|
||||||
// Allow escape key hook and other editor events to close context menu
|
// Allow escape key hook and other editor events to close context menu
|
||||||
RED.keyboard.add("red-ui-workspace-context-menu", "escape", function () { RED.contextMenu.hide() })
|
RED.keyboard.add("red-ui-workspace-context-menu", "escape", function () { RED.contextMenu.hide() })
|
||||||
|
RED.events.on("editor:open",function() { RED.contextMenu.hide() });
|
||||||
|
RED.events.on("search:open",function() { RED.contextMenu.hide() });
|
||||||
|
RED.events.on("type-search:open",function() { RED.contextMenu.hide() });
|
||||||
|
RED.events.on("actionList:open",function() { RED.contextMenu.hide() });
|
||||||
|
RED.events.on("view:selection-changed",function() { RED.contextMenu.hide() });
|
||||||
return {
|
return {
|
||||||
show: show,
|
show: show,
|
||||||
hide: disposeMenu
|
hide: disposeMenu
|
||||||
|
Loading…
Reference in New Issue
Block a user