From b6992659d1ae1399316a9d5211937c49d05772a4 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Wed, 22 Jan 2014 19:39:26 -0500 Subject: [PATCH] fix image stretching in web client --- dashboard-ui/scripts/autoorganizelog.js | 2 -- dashboard-ui/scripts/librarybrowser.js | 10 ++++------ 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/dashboard-ui/scripts/autoorganizelog.js b/dashboard-ui/scripts/autoorganizelog.js index 64b8276d2..8f2ab1a01 100644 --- a/dashboard-ui/scripts/autoorganizelog.js +++ b/dashboard-ui/scripts/autoorganizelog.js @@ -307,10 +307,8 @@ if (result.TotalRecordCount) { $('.btnClearLog', page).show(); - $('.legend', page).show(); } else { $('.btnClearLog', page).hide(); - $('.legend', page).hide(); } } diff --git a/dashboard-ui/scripts/librarybrowser.js b/dashboard-ui/scripts/librarybrowser.js index 7fa5f5610..588fd157c 100644 --- a/dashboard-ui/scripts/librarybrowser.js +++ b/dashboard-ui/scripts/librarybrowser.js @@ -684,7 +684,7 @@ var html = ""; - var primaryImageAspectRatio = options.useAverageAspectRatio || options.shape == 'auto' ? LibraryBrowser.getAveragePrimaryImageAspectRatio(items) : null; + var primaryImageAspectRatio = options.shape == 'auto' ? LibraryBrowser.getAveragePrimaryImageAspectRatio(items) : null; if (options.shape == 'auto') { @@ -699,14 +699,12 @@ } } - if (!options.useAverageAspectRatio) { - primaryImageAspectRatio = null; - } - for (var i = 0, length = items.length; i < length; i++) { var item = items[i]; + primaryImageAspectRatio = options.useAverageAspectRatio ? LibraryBrowser.getAveragePrimaryImageAspectRatio([item]) : null; + var futureDateText; if (item.PremiereDate) { @@ -1498,7 +1496,7 @@ html += '
'; html += item.CommunityRating.toFixed(1); html += '
'; - } + } if (item.CriticRating != null) {