diff -r a276b36ae58e -r 4f92e61f87ba client/js/renderer/nodeeditor.js --- a/client/js/renderer/nodeeditor.js Wed Sep 10 16:58:01 2014 +0200 +++ b/client/js/renderer/nodeeditor.js Thu Sep 11 16:49:45 2014 +0200 @@ -21,7 +21,15 @@ '<% if (node.clip_path) { %><% }%>' + '

' + '

<% } %>' + - '<% if (options.show_node_editor_creator && node.has_creator) { %>

<%-renkan.translate("Created by:")%> <%- shortenText(node.created_by_title, 25) %>

<% } %>' + '<% if (options.show_node_editor_creator && node.has_creator) { %>

<%-renkan.translate("Created by:")%> <%- shortenText(node.created_by_title, 25) %>

<% } %>' + + '<% if (options.change_shapes) { %>

<% } %>' ), readOnlyTemplate: _.template( '

×<% if (options.show_node_tooltip_color) { %><% } %>' + @@ -51,7 +59,8 @@ clip_path: _model.get("clip_path") || false, created_by_color: _created_by.get("color"), created_by_title: _created_by.get("title"), - size: (_size > 0 ? "+" : "") + _size + size: (_size > 0 ? "+" : "") + _size, + shape: _model.get("shape") || "circle" }, renkan: this.renkan, options: this.options, @@ -78,7 +87,7 @@ _(function() { if (_this.renderer.isEditable()) { var _data = { - title: _this.editor_$.find(".Rk-Edit-Title").val() + title: _this.editor_$.find(".Rk-Edit-Title").val() }; if (_this.options.show_node_editor_uri) { _data.uri = _this.editor_$.find(".Rk-Edit-URI").val(); @@ -91,12 +100,15 @@ if (_this.options.show_node_editor_description) { _data.description = _this.editor_$.find(".Rk-Edit-Description").val(); } + if (_this.options.change_shapes) { + _data.shape = _this.editor_$.find(".Rk-Edit-Shape").val(); + _data.shape_changed = true; + } _model.set(_data); _this.redraw(); } else { closeEditor(); } - }).defer(); }).throttle(500); @@ -106,7 +118,7 @@ } }); - this.editor_$.find("input, textarea").on("change keyup paste", onFieldChange); + this.editor_$.find("input, textarea, select").on("change keyup paste", onFieldChange); this.editor_$.find(".Rk-Edit-Image-File").change(function() { if (this.files.length) {