From a2a6b4f504e4c24141e020bc6e1f159283d700ef Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Fri, 11 Nov 2011 01:32:17 +0100 Subject: [PATCH] Removed unnecessary code --- wcfsetup/install/files/js/WCF.js | 23 ++++++----------------- 1 file changed, 6 insertions(+), 17 deletions(-) diff --git a/wcfsetup/install/files/js/WCF.js b/wcfsetup/install/files/js/WCF.js index a412b70c76..820573b40a 100644 --- a/wcfsetup/install/files/js/WCF.js +++ b/wcfsetup/install/files/js/WCF.js @@ -3002,6 +3002,8 @@ $.widget('ui.wcfSidebar', { */ _button: null, + _container: null, + /** * sidebar visibility * @var boolean @@ -3013,9 +3015,10 @@ $.widget('ui.wcfSidebar', { */ _create: function() { this.element.wrap('
'); + this._container = this.element.parent('div'); // create toggle button - this._button = $('').appendTo(this.element.parent('div')); + this._button = $('').appendTo(this._container); // bind event this._button.click($.proxy(this._toggle, this)); @@ -3042,14 +3045,7 @@ $.widget('ui.wcfSidebar', { } this._visible = true; - this.element.parent('div').removeClass('collapsedSidebar'); - this._button.html('«'); - - /* - this.element.wcfBlindIn('horizontal', $.proxy(function() { - this._button.html('«'); - }, this)); - */ + this._container.removeClass('collapsedSidebar'); }, /** @@ -3061,14 +3057,7 @@ $.widget('ui.wcfSidebar', { } this._visible = false; - this.element.parent('div').addClass('collapsedSidebar'); - this._button.html('»'); - - /* - this.element.wcfBlindOut('horizontal', $.proxy(function() { - this._button.html('»'); - }, this)); - */ + this._container.addClass('collapsedSidebar'); } }); -- 2.20.1