From 0525d02dca374a1cf1c5f3a8fbfc17aa27a117b9 Mon Sep 17 00:00:00 2001 From: rolux Date: Fri, 23 Dec 2011 05:06:06 +0000 Subject: [PATCH] fix a bug related to filter swapping --- static/js/pandora/URL.js | 3 +++ static/js/pandora/filter.js | 11 +++-------- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/static/js/pandora/URL.js b/static/js/pandora/URL.js index 2c3335ec..a557fa68 100644 --- a/static/js/pandora/URL.js +++ b/static/js/pandora/URL.js @@ -247,6 +247,9 @@ pandora.URL = (function() { if (pandora.$ui.home) { pandora.UI.set({page: ''}); pandora.$ui.home.fadeOutScreen(); + } else if (pandora.$ui.tv) { + pandora.UI.set({page: ''}); + pandora.$ui.home.fadeOutScreen(); } if ( pandora.user.ui.item diff --git a/static/js/pandora/filter.js b/static/js/pandora/filter.js index ec93abd7..54d7beff 100644 --- a/static/js/pandora/filter.js +++ b/static/js/pandora/filter.js @@ -157,16 +157,11 @@ pandora.ui.filter = function(id) { } }); Ox.Select({ - items: pandora.site.filters.map(function(filter) { - return { - checked: filter.id == id, - id: filter.id, - title: filter.title - } - }), + items: Ox.clone(pandora.site.filters), max: 1, min: 1, - type: 'image' + type: 'image', + value: id }) .bindEvent('change', function(data) { var filters = Ox.clone(pandora.user.ui.filters),