mirror of
https://github.com/node-red/node-red
synced 2024-11-21 23:48:30 +00:00
Hide actionList in context menu if disabled
This commit is contained in:
parent
9745904c5b
commit
593726ecb8
@ -205,7 +205,9 @@ RED.actionList = (function() {
|
||||
}
|
||||
|
||||
function init() {
|
||||
RED.actions.add("core:show-action-list",show);
|
||||
if (RED.settings.theme("menu.menu-item-action-list", true)) {
|
||||
RED.actions.add("core:show-action-list",show);
|
||||
}
|
||||
|
||||
RED.events.on("editor:open",function() { disabled = true; });
|
||||
RED.events.on("editor:close",function() { disabled = false; });
|
||||
|
@ -65,10 +65,11 @@ RED.contextMenu = (function () {
|
||||
addY = gridSize * Math.floor(addY / gridSize)
|
||||
}
|
||||
|
||||
menuItems.push(
|
||||
{ onselect: 'core:show-action-list', label: RED._("contextMenu.showActionList"), onpostselect: function () { } }
|
||||
)
|
||||
|
||||
if (RED.settings.theme("menu.menu-item-action-list", true)) {
|
||||
menuItems.push(
|
||||
{ onselect: 'core:show-action-list', label: RED._("contextMenu.showActionList"), onpostselect: function () { } }
|
||||
)
|
||||
}
|
||||
const insertOptions = []
|
||||
menuItems.push({ label: RED._("contextMenu.insert"), options: insertOptions })
|
||||
insertOptions.push(
|
||||
|
Loading…
Reference in New Issue
Block a user