From 823cea5b1fc8a51b818e2a3a7784aac0c94447e7 Mon Sep 17 00:00:00 2001 From: Mike Taylor Date: Thu, 1 May 2014 12:10:49 +0100 Subject: [PATCH] resizePage now use team.widget method to find widgets to show/hide. This works correctly when the implicit AUTO team is used. --- src/mkws-core.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/mkws-core.js b/src/mkws-core.js index ff619bd..1ff2f2e 100644 --- a/src/mkws-core.js +++ b/src/mkws-core.js @@ -330,7 +330,7 @@ mkws.pagerNext = function(tname) { function resizePage() { - var list = ["mkwsSwitch", "mkwsLang"]; + var list = ["Switch", "Lang"]; var threshhold = mkws.config.responsive_design_width; var width = $(window).width(); @@ -353,7 +353,8 @@ mkws.pagerNext = function(tname) { mkws.teams[tname].queue("resize" + to).publish(); $(".mkwsTermlists.mkwsTeam_" + tname).appendTo($(".mkwsTermlist-Container-" + to + ".mkwsTeam_" + tname)); for(var i = 0; i < list.length; i++) { - $("." + list[i] + ".mkwsTeam_" + tname)[method](); + var widget = mkws.teams[tname].widget(list[i]); + if (widget) $(widget.node)[method](); } } } -- 1.7.10.4