From a7f5a4e6630c2be94ae77a605e3c5c6f46183c41 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Tue, 17 Dec 2019 09:21:20 +0100 Subject: [PATCH] Fixing bugs on menu at schema --- FloatingSpace/UiObjectConstructor.js | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/FloatingSpace/UiObjectConstructor.js b/FloatingSpace/UiObjectConstructor.js index dcbced3b2..2ac33c0dd 100644 --- a/FloatingSpace/UiObjectConstructor.js +++ b/FloatingSpace/UiObjectConstructor.js @@ -81,8 +81,28 @@ function newUiObjectConstructor () { if (item.action.indexOf('Delete ') >= 0) { // item.action = 'Delete UI Object' } + if (item.action.indexOf('Configure ') >= 0) { + if (schemaNode.editors.config === true) { + // item.actionFunction = 'uiObject.configEditor.activate' + } + } + if (item.action.indexOf('Edit ') >= 0) { + if (schemaNode.editors.condition === true) { + // item.actionFunction = 'uiObject.conditionEditor.activate' + } + } + if (item.action.indexOf('Edit ') >= 0) { + if (schemaNode.editors.formula === true) { + // item.actionFunction = 'uiObject.formulaEditor.activate' + } + } + if (item.action.indexOf('Edit ') >= 0) { + if (schemaNode.editors.code === true) { + // item.actionFunction = 'uiObject.codeEditor.activate' + } + } if (item.actionFunction === undefined) { - item.actionFunction = 'payload.onMenuItemClick' + // item.actionFunction = 'payload.onMenuItemClick' } } }