From: Aleksander Ɓukasz Date: Thu, 3 Apr 2014 09:52:08 +0000 (+0200) Subject: fix: canvas again gets opportunity to react to footnote being closed X-Git-Url: https://git.mdrn.pl/fnpeditor.git/commitdiff_plain/804d77fa4cea068e90b6461f1a5f151fe6f67fbc?hp=4a1c68596333765b36f36a9cf88942f90c20efab fix: canvas again gets opportunity to react to footnote being closed --- diff --git a/src/editor/modules/documentCanvas/canvas/documentElement.js b/src/editor/modules/documentCanvas/canvas/documentElement.js index 7b7f7f9..b2e25ed 100644 --- a/src/editor/modules/documentCanvas/canvas/documentElement.js +++ b/src/editor/modules/documentCanvas/canvas/documentElement.js @@ -52,7 +52,7 @@ $.extend(DocumentElement.prototype, { }, trigger: function() { - //this.canvas.bus.trigger() + this.canvas.eventBus.trigger.apply(this.canvas.eventBus, Array.prototype.slice.call(arguments, 0)); } diff --git a/src/editor/plugins/core/canvasElements.js b/src/editor/plugins/core/canvasElements.js index b0f51b6..e74adee 100644 --- a/src/editor/plugins/core/canvasElements.js +++ b/src/editor/plugins/core/canvasElements.js @@ -100,7 +100,7 @@ var footnote = { } this._container().toggle(toggle); if(!options.silent) { - this.trigger('elementToggled', toggle, this.documentElement); + this.trigger('elementToggled', toggle, this); } } };