X-Git-Url: https://git.mdrn.pl/fnpeditor.git/blobdiff_plain/4a10da821d96b8e462cc9db5e74e2507445eee76..f07cd8d76ad2bc0fbfada50ad35bad4f4b307267:/modules/nodePane/nodePane.js?ds=inline diff --git a/modules/nodePane/nodePane.js b/modules/nodePane/nodePane.js index cc71d35..57f5c17 100644 --- a/modules/nodePane/nodePane.js +++ b/modules/nodePane/nodePane.js @@ -1,35 +1,35 @@ -define([ -'libs/text!./template.html', -'libs/jquery-1.9.1.min', -'libs/underscore-min', - -], function(templateSrc, $, _) { - -'use strict'; - -return function(sandbox) { - - var view = $(_.template(templateSrc)()); - - view.on('change', 'select', function(e) { - var target = $(e.target); - var attr = target.attr('class').split('-')[3] === 'tagSelect' ? 'tag' : 'class'; - sandbox.publish('nodeChanged', attr, target.val()); - }); - - return { - start: function() { - sandbox.publish('ready'); - }, - getView: function() { - return view; - }, - setNode: function(canvasNode) { - view.find('.rng-module-nodePane-tagSelect').val(canvasNode.getTag()); - view.find('.rng-module-nodePane-classSelect').val(canvasNode.getClass()); - } - }; - -}; - +define([ +'libs/text!./template.html', +'libs/jquery-1.9.1.min', +'libs/underscore-min', + +], function(templateSrc, $, _) { + +'use strict'; + +return function(sandbox) { + + var view = $(_.template(templateSrc)()); + + view.on('change', 'select', function(e) { + var target = $(e.target); + var attr = target.attr('class').split('-')[3] === 'tagSelect' ? 'tag' : 'class'; + sandbox.publish('nodeChanged', attr, target.val()); + }); + + return { + start: function() { + sandbox.publish('ready'); + }, + getView: function() { + return view; + }, + setNode: function(canvasNode) { + view.find('.rng-module-nodePane-tagSelect').val(canvasNode.getTag()); + view.find('.rng-module-nodePane-classSelect').val(canvasNode.getClass()); + } + }; + +}; + }); \ No newline at end of file