forked from 0x2620/pandora
poster keys
This commit is contained in:
parent
8bb7ae436f
commit
1ce1ca7d89
3 changed files with 14 additions and 4 deletions
|
@ -28,6 +28,7 @@ pandora.ui.infoView = function(data) {
|
||||||
listKeys = nameKeys.concat([
|
listKeys = nameKeys.concat([
|
||||||
'country', 'language', 'color', 'sound', 'genre', 'keyword', 'links'
|
'country', 'language', 'color', 'sound', 'genre', 'keyword', 'links'
|
||||||
]),
|
]),
|
||||||
|
posterKeys = ['title', 'director', 'year'],
|
||||||
// these may contain commas, and are thus separated by semicolons
|
// these may contain commas, and are thus separated by semicolons
|
||||||
specialListKeys = ['alternativeTitles', 'productionCompany'],
|
specialListKeys = ['alternativeTitles', 'productionCompany'],
|
||||||
descriptions = {
|
descriptions = {
|
||||||
|
@ -491,10 +492,7 @@ pandora.ui.infoView = function(data) {
|
||||||
}
|
}
|
||||||
pandora.updateItemContext();
|
pandora.updateItemContext();
|
||||||
pandora.$ui.browser.value(result.data.id, key, result.data[key]);
|
pandora.$ui.browser.value(result.data.id, key, result.data[key]);
|
||||||
if (
|
if (Ox.contains(posterKeys, key) && ui.icons == 'posters') {
|
||||||
Ox.contains(['title', 'director', 'year'], key)
|
|
||||||
&& ui.icons == 'posters'
|
|
||||||
) {
|
|
||||||
src = pandora.getMediaURL('/' + data.id + '/poster512.jpg?' + Ox.uid());
|
src = pandora.getMediaURL('/' + data.id + '/poster512.jpg?' + Ox.uid());
|
||||||
$icon.attr({src: src});
|
$icon.attr({src: src});
|
||||||
$reflectionIcon.attr({src: src});
|
$reflectionIcon.attr({src: src});
|
||||||
|
|
|
@ -20,6 +20,7 @@ pandora.ui.infoView = function(data) {
|
||||||
margin = 16,
|
margin = 16,
|
||||||
nameKeys = ['director'],
|
nameKeys = ['director'],
|
||||||
listKeys = nameKeys.concat(['country', 'groups']),
|
listKeys = nameKeys.concat(['country', 'groups']),
|
||||||
|
posterKeys = nameKeys.concat(['title', 'year']),
|
||||||
statisticsWidth = 128,
|
statisticsWidth = 128,
|
||||||
|
|
||||||
$bar = Ox.Bar({size: 16})
|
$bar = Ox.Bar({size: 16})
|
||||||
|
@ -361,6 +362,11 @@ pandora.ui.infoView = function(data) {
|
||||||
}
|
}
|
||||||
pandora.updateItemContext();
|
pandora.updateItemContext();
|
||||||
pandora.$ui.browser.value(result.data.id, key, result.data[key]);
|
pandora.$ui.browser.value(result.data.id, key, result.data[key]);
|
||||||
|
if (Ox.contains(posterKeys, key) && ui.icons == 'posters') {
|
||||||
|
src = pandora.getMediaURL('/' + data.id + '/poster512.jpg?' + Ox.uid());
|
||||||
|
$icon.attr({src: src});
|
||||||
|
$reflectionIcon.attr({src: src});
|
||||||
|
}
|
||||||
pandora.$ui.itemTitle
|
pandora.$ui.itemTitle
|
||||||
.options({
|
.options({
|
||||||
title: '<b>' + result.data.title
|
title: '<b>' + result.data.title
|
||||||
|
|
|
@ -20,6 +20,7 @@ pandora.ui.infoView = function(data) {
|
||||||
margin = 16,
|
margin = 16,
|
||||||
nameKeys = ['director', 'cinematographer', 'featuring'],
|
nameKeys = ['director', 'cinematographer', 'featuring'],
|
||||||
listKeys = nameKeys.concat(['language', 'topic', 'license', 'groups']),
|
listKeys = nameKeys.concat(['language', 'topic', 'license', 'groups']),
|
||||||
|
posterKeys = ['title', 'date'],
|
||||||
statisticsWidth = 128,
|
statisticsWidth = 128,
|
||||||
|
|
||||||
$bar = Ox.Bar({size: 16})
|
$bar = Ox.Bar({size: 16})
|
||||||
|
@ -529,6 +530,11 @@ pandora.ui.infoView = function(data) {
|
||||||
}
|
}
|
||||||
pandora.updateItemContext();
|
pandora.updateItemContext();
|
||||||
pandora.$ui.browser.value(result.data.id, key, result.data[key]);
|
pandora.$ui.browser.value(result.data.id, key, result.data[key]);
|
||||||
|
if (Ox.contains(posterKeys, key) && ui.icons == 'posters') {
|
||||||
|
src = pandora.getMediaURL('/' + data.id + '/poster512.jpg?' + Ox.uid());
|
||||||
|
$icon.attr({src: src});
|
||||||
|
$reflectionIcon.attr({src: src});
|
||||||
|
}
|
||||||
pandora.$ui.itemTitle
|
pandora.$ui.itemTitle
|
||||||
.options({
|
.options({
|
||||||
title: '<b>' + result.data.title
|
title: '<b>' + result.data.title
|
||||||
|
|
Loading…
Reference in a new issue