From a1dac1e2903acccf242adf888f4f185aaad10f91 Mon Sep 17 00:00:00 2001 From: Nick O'Leary Date: Tue, 17 Mar 2015 13:36:50 +0000 Subject: [PATCH] Resize ace editor on dialog-open --- nodes/core/core/80-function.html | 2 +- nodes/core/core/80-template.html | 2 +- nodes/core/core/90-comment.html | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/nodes/core/core/80-function.html b/nodes/core/core/80-function.html index f581574ac..c415f9791 100644 --- a/nodes/core/core/80-function.html +++ b/nodes/core/core/80-function.html @@ -83,7 +83,6 @@ }); function functionDialogResize() { - that.editor.resize(); var rows = $("#dialog-form>div:not(.node-text-editor-row)"); var height = $("#dialog-form").height(); for (var i=0;idiv.node-text-editor-row"); height -= (parseInt(editorRow.css("marginTop"))+parseInt(editorRow.css("marginBottom"))); $(".node-text-editor").css("height",height+"px"); + that.editor.resize(); }; $( "#dialog" ).on("dialogresize", functionDialogResize); $( "#dialog" ).one("dialogopen", function(ev) { diff --git a/nodes/core/core/80-template.html b/nodes/core/core/80-template.html index f88c8c5ab..cdf6ea495 100644 --- a/nodes/core/core/80-template.html +++ b/nodes/core/core/80-template.html @@ -73,7 +73,6 @@ oneditprepare: function() { var that = this; function templateDialogResize() { - that.editor.resize(); var rows = $("#dialog-form>div:not(.node-text-editor-row)"); var height = $("#dialog-form").height(); for (var i=0;idiv.node-text-editor-row"); height -= (parseInt(editorRow.css("marginTop"))+parseInt(editorRow.css("marginBottom"))); $(".node-text-editor").css("height",height+"px"); + that.editor.resize(); }; $( "#dialog" ).on("dialogresize", templateDialogResize); $( "#dialog" ).one("dialogopen", function(ev) { diff --git a/nodes/core/core/90-comment.html b/nodes/core/core/90-comment.html index fd4106817..5bd3dd6df 100644 --- a/nodes/core/core/90-comment.html +++ b/nodes/core/core/90-comment.html @@ -61,7 +61,6 @@ min:1 }); function functionDialogResize() { - that.editor.resize(); var rows = $("#dialog-form>div:not(.node-text-editor-row)"); var height = $("#dialog-form").height(); for (var i=0;idiv.node-text-editor-row"); height -= (parseInt(editorRow.css("marginTop"))+parseInt(editorRow.css("marginBottom"))); $(".node-text-editor").css("height",height+"px"); + that.editor.resize(); }; $( "#dialog" ).on("dialogresize", functionDialogResize); $( "#dialog" ).one("dialogopen", function(ev) {