From: Alexander Ebert Date: Fri, 6 Jun 2014 10:40:42 +0000 (+0200) Subject: Fixed dropdowns X-Git-Tag: 2.1.0_Alpha_1~745 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e552e10bb1799a7caaafa4dda5714287365105b3;p=GitHub%2FWoltLab%2FWCF.git Fixed dropdowns --- diff --git a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js index 2ec03941e9..d03a6ee914 100644 --- a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js +++ b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js @@ -12,12 +12,12 @@ RedactorPlugins.wbbcode = { * Initializes the RedactorPlugins.wbbcode plugin. */ init: function() { - this._createSmileyDropdown(); - + var $dropdown = this._createSmileyDropdown(); this.buttonReplace('smiley', 'wsmiley', 'Smiley', $.proxy(function(btnName, $button, btnObject, e) { this.dropdownShow(e, btnName); }, this)); + this.buttonGet('wsmiley').data('dropdown', $dropdown); this.buttonAwesome('wsmiley', 'fa-smile-o'); this.opts.initCallback = $.proxy(function() { @@ -44,6 +44,8 @@ RedactorPlugins.wbbcode = { } $(this.$toolbar).append($dropdown); + + return $dropdown; }, /** diff --git a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wfontcolor.js b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wfontcolor.js index f2468f12b3..610363ac1a 100644 --- a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wfontcolor.js +++ b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wfontcolor.js @@ -12,12 +12,12 @@ RedactorPlugins.wfontcolor = { * Initializes the RedactorPlugins.wfontcolor plugin. */ init: function() { - this._createFontColorDropdown(); + var $dropdown = this._createFontColorDropdown(); this.buttonReplace('fontcolor', 'fontcolor', this.opts.curLang.fontcolor, $.proxy(function(btnName, $button, btnObject, e) { this.dropdownShow(e, btnName); }, this)); - //this.buttonAwesome('fontcolor', 'fa-font'); + this.buttonGet('fontcolor').data('dropdown', $dropdown); }, /** @@ -46,6 +46,8 @@ RedactorPlugins.wfontcolor = { $dropdown.append($elNone); $(this.$toolbar).append($dropdown); + + return $dropdown; }, /**