Passing reference to Redactor object in BBCode-button event
authorAlexander Ebert <ebert@woltlab.com>
Thu, 15 Jan 2015 14:38:00 +0000 (15:38 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Thu, 15 Jan 2015 14:38:00 +0000 (15:38 +0100)
wcfsetup/install/files/js/3rdParty/redactor/plugins/wbutton.js

index 37813102a77baf08da146752f891cbb182300d28..77eb7c6bc8e540e832f997d2436246bfb1a9626e 100644 (file)
@@ -145,7 +145,8 @@ RedactorPlugins.wbutton = function() {
                        var $bbcode = this._bbcodes[buttonName].name;
                        var $eventData = {
                                buttonName: buttonName,
-                               cancel: false
+                               cancel: false,
+                               redactor: this
                        };
                        
                        WCF.System.Event.fireEvent('com.woltlab.wcf.redactor', 'insertBBCode_' + $bbcode + '_' + this.$textarea.wcfIdentify(), $eventData);