From 2a20116a0dd053dd62752e7f50ef32ec68f20bf2 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Fri, 14 Jun 2013 02:18:27 +0200 Subject: [PATCH] Fixed poll options not properly resizing if tab was inactive --- wcfsetup/install/files/js/WCF.Poll.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/wcfsetup/install/files/js/WCF.Poll.js b/wcfsetup/install/files/js/WCF.Poll.js index d8fa2a59d1..f085a054e5 100644 --- a/wcfsetup/install/files/js/WCF.Poll.js +++ b/wcfsetup/install/files/js/WCF.Poll.js @@ -51,6 +51,16 @@ WCF.Poll.Management = Class.extend({ // trigger resize event for field length calculation this._resize(); + + // update size on tab select + var $tabMenuContent = this._container.parents('.tabMenuContent:eq(0)'); + var $tabMenuContentID = $tabMenuContent.wcfIdentify(); + var self = this; + $tabMenuContent.parents('.tabMenuContainer:eq(0)').on('wcftabsactivate', function(event, ui) { + if (ui.newPanel.wcfIdentify() == $tabMenuContentID) { + self._resize(); + } + }); }, /** -- 2.20.1