Some cleanup
authorAlexander Ebert <ebert@woltlab.com>
Wed, 9 Jul 2014 09:26:22 +0000 (11:26 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Wed, 9 Jul 2014 09:26:22 +0000 (11:26 +0200)
wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js

index 20ee49384d28f9d50e34903b397d6263a4e4a82f..3d235e736ea9af376dbef20553d51054d5b2f2e7 100644 (file)
@@ -12,14 +12,6 @@ RedactorPlugins.wbbcode = {
         * Initializes the RedactorPlugins.wbbcode plugin.
         */
        init: function() {
-               /*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() {
                        if (this.$source.val().length) {
                                this.toggle();
@@ -86,33 +78,6 @@ RedactorPlugins.wbbcode = {
                }
        },
        
-       /**
-        * Creates the smiley dropdown.
-        */
-       _createSmileyDropdown: function() {
-               var $dropdown = $('<div class="redactor_dropdown redactor_dropdown_box_wsmiley" style="display: none; width: 195px;" />');
-               var $list = $('<ul class="smileyList" />').appendTo($dropdown);
-               
-               for (var $smileyCode in __REDACTOR_SMILIES) {
-                       var $insertLink = $('<li><img src="' + __REDACTOR_SMILIES[$smileyCode] + '" class="smiley" /></li>').data('smileyCode', $smileyCode);
-                       $insertLink.appendTo($list).click($.proxy(this._onSmileyPick, this));
-               }
-               
-               $(this.$toolbar).append($dropdown);
-               
-               return $dropdown;
-       },
-       
-       /**
-        * Inserts smiley on click.
-        * 
-        * @param       object          event
-        */
-       _onSmileyPick: function(event) {
-               var $smileyCode = $(event.currentTarget).data('smileyCode');
-               this.insertSmiley($smileyCode, __REDACTOR_SMILIES[$smileyCode], false);
-       },
-       
        /**
         * Inserts a smiley, optionally trying to register a new smiley.
         *