From: Aleksander Ɓukasz Date: Thu, 10 Oct 2013 10:34:56 +0000 (+0200) Subject: fix X-Git-Url: https://git.mdrn.pl/fnpeditor.git/commitdiff_plain/2eeacc82afeed21114a35b91fcaa88db89523153 fix --- diff --git a/src/editor/modules/documentCanvas/canvas/canvas.js b/src/editor/modules/documentCanvas/canvas/canvas.js index 8c2e2e1..c0eeaf0 100644 --- a/src/editor/modules/documentCanvas/canvas/canvas.js +++ b/src/editor/modules/documentCanvas/canvas/canvas.js @@ -11,6 +11,7 @@ define([ var Canvas = function(wlxmlDocument, publisher) { this.eventBus = _.extend({}, Backbone.Events); + this.wrapper = $('
').addClass('canvas-wrapper').attr('contenteditable', true); this.loadWlxmlDocument(wlxmlDocument); this.publisher = publisher ? publisher : function() {}; }; @@ -23,7 +24,7 @@ $.extend(Canvas.prototype, { } var canvasDOM = this.generateCanvasDOM(wlxmlDocument.root); - this.wrapper = $('
').addClass('canvas-wrapper').attr('contenteditable', true); + this.wrapper.empty(); this.wrapper.append(canvasDOM); this.d = this.wrapper.children(0); this.setupEventHandling();