1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

restored external subtitle support

This commit is contained in:
Luke Pulverenti 2014-02-10 13:39:41 -05:00
parent a43da6cd63
commit 96460b1880
2 changed files with 133 additions and 98 deletions

View file

@ -9,7 +9,7 @@
<div data-role="content"> <div data-role="content">
<div class="content-primary"> <div class="content-primary">
<div data-role="controlgroup" data-type="horizontal" class="localnav" data-mini="true" style="margin-bottom: 20px!important;"> <div data-role="controlgroup" data-type="horizontal" class="localnav" data-mini="true" style="margin-bottom: 30px!important;">
<a href="metadata.html" data-role="button">Basics</a> <a href="metadata.html" data-role="button">Basics</a>
<a href="metadataimages.html?type=movies" data-role="button" class="categoryTab moviesTab">Movies</a> <a href="metadataimages.html?type=movies" data-role="button" class="categoryTab moviesTab">Movies</a>
<a href="metadataimages.html?type=tv" data-role="button" class="categoryTab tvTab">TV</a> <a href="metadataimages.html?type=tv" data-role="button" class="categoryTab tvTab">TV</a>
@ -27,90 +27,96 @@
<br /> <br />
<div class="tabContent"> <div class="tabContent">
<form class="metadataImagesConfigurationForm"> <form class="metadataImagesConfigurationForm" style="margin-top: .5em;">
<div class="metadataReaders" style="margin-bottom: 2em;"> <div class="metadataReaders" style="margin-bottom: 2.5em;">
</div> </div>
<div class="metadataFetchers" style="margin-bottom: 2em;"> <div class="metadataFetchers" style="margin-bottom: 2.5em;">
</div> </div>
<div class="metadataSavers" style="margin-bottom: 2em;"> <div class="metadataSavers" style="margin-bottom: 2.5em;">
</div> </div>
<div class="imageFetchers" style="margin-bottom: 2em;"> <div class="imageFetchers" style="margin-bottom: 2.5em;">
</div> </div>
<div class="backdropFields" style="margin-bottom: 2em; display: none;"> <div data-role="collapsible">
<h2>Image Settings</h2>
<div> <div>
<label for="txtMaxBackdrops">Max number of backdrops per item: </label> <br />
<input type="number" id="txtMaxBackdrops" name="txtMaxBackdrops" pattern="[0-9]*" required="required" min="0" data-mini="true" /> <div class="backdropFields" style="margin-bottom: 2em; display: none;">
</div> <div>
<label for="txtMaxBackdrops">Maximum number of backdrops per item: </label>
<input type="number" id="txtMaxBackdrops" name="txtMaxBackdrops" pattern="[0-9]*" required="required" min="0" data-mini="true" />
</div>
<div> <div>
<label for="txtMinBackdropDownloadWidth">Minimum backdrop download width: </label> <label for="txtMinBackdropDownloadWidth">Minimum backdrop download width: </label>
<input type="number" id="txtMinBackdropDownloadWidth" name="txtMinBackdropDownloadWidth" pattern="[0-9]*" required="required" min="0" data-mini="true" /> <input type="number" id="txtMinBackdropDownloadWidth" name="txtMinBackdropDownloadWidth" pattern="[0-9]*" required="required" min="0" data-mini="true" />
</div>
</div>
<div class="screenshotFields" style="margin-bottom: 2em; display: none;">
<div>
<label for="txtMaxScreenshots">Maximum number of screenshots per item: </label>
<input type="number" id="txtMaxScreenshots" name="txtMaxScreenshots" pattern="[0-9]*" required="required" min="0" data-mini="true" />
</div>
<div>
<label for="txtMinScreenshotDownloadWidth">Minimum screenshot download width: </label>
<input type="number" id="txtMinScreenshotDownloadWidth" name="txtMinScreenshotDownloadWidth" pattern="[0-9]*" required="required" min="0" data-mini="true" />
</div>
</div>
<fieldset data-role="controlgroup" style="border-bottom: 1px solid #ddd;">
<legend>Fetch Images:</legend>
<div class="imageType" data-imagetype="Primary" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadPrimary" name="chkDownloadPrimary" />
<label for="chkDownloadPrimary">Primary</label>
</div>
<div class="imageType" data-imagetype="Art" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadArt" name="chkDownloadArt" />
<label for="chkDownloadArt">Art</label>
</div>
<div class="imageType" data-imagetype="BoxRear" style="display: none;">
<input type="checkbox" data-mini="true" id="chkBack" name="chkBack" />
<label for="chkBack">Back</label>
</div>
<div class="imageType" data-imagetype="Banner" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadBanner" name="chkDownloadBanner" />
<label for="chkDownloadBanner">Banner</label>
</div>
<div class="imageType" data-imagetype="Box" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadBox" name="chkDownloadBox" />
<label for="chkDownloadBox">Box</label>
</div>
<div class="imageType" data-imagetype="Disc" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadDisc" name="chkDownloadDisc" />
<label for="chkDownloadDisc">Disc</label>
</div>
<div class="imageType" data-imagetype="Logo" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadLogo" name="chkDownloadLogo" />
<label for="chkDownloadLogo">Logo</label>
</div>
<div class="imageType" data-imagetype="Menu" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadMenu" name="chkDownloadMenu" />
<label for="chkDownloadMenu">Menu</label>
</div>
<div class="imageType" data-imagetype="Thumb" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadThumb" name="chkDownloadThumb" />
<label for="chkDownloadThumb">Thumb</label>
</div>
</fieldset>
</div> </div>
</div> </div>
<div class="screenshotFields" style="margin-bottom: 2em; display: none;">
<div>
<label for="txtMaxScreenshots">Max number of screenshots per item: </label>
<input type="number" id="txtMaxScreenshots" name="txtMaxScreenshots" pattern="[0-9]*" required="required" min="0" data-mini="true" />
</div>
<div>
<label for="txtMinScreenshotDownloadWidth">Minimum screenshot download width: </label>
<input type="number" id="txtMinScreenshotDownloadWidth" name="txtMinScreenshotDownloadWidth" pattern="[0-9]*" required="required" min="0" data-mini="true" />
</div>
</div>
<fieldset data-role="controlgroup" style="border-bottom: 1px solid #ddd;">
<legend>Fetch Images:</legend>
<div class="imageType" data-imagetype="Primary" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadPrimary" name="chkDownloadPrimary" />
<label for="chkDownloadPrimary">Primary</label>
</div>
<div class="imageType" data-imagetype="Art" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadArt" name="chkDownloadArt" />
<label for="chkDownloadArt">Art</label>
</div>
<div class="imageType" data-imagetype="BoxRear" style="display: none;">
<input type="checkbox" data-mini="true" id="chkBack" name="chkBack" />
<label for="chkBack">Back</label>
</div>
<div class="imageType" data-imagetype="Banner" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadBanner" name="chkDownloadBanner" />
<label for="chkDownloadBanner">Banner</label>
</div>
<div class="imageType" data-imagetype="Box" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadBox" name="chkDownloadBox" />
<label for="chkDownloadBox">Box</label>
</div>
<div class="imageType" data-imagetype="Disc" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadDisc" name="chkDownloadDisc" />
<label for="chkDownloadDisc">Disc</label>
</div>
<div class="imageType" data-imagetype="Logo" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadLogo" name="chkDownloadLogo" />
<label for="chkDownloadLogo">Logo</label>
</div>
<div class="imageType" data-imagetype="Menu" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadMenu" name="chkDownloadMenu" />
<label for="chkDownloadMenu">Menu</label>
</div>
<div class="imageType" data-imagetype="Thumb" style="display: none;">
<input type="checkbox" data-mini="true" id="chkDownloadThumb" name="chkDownloadThumb" />
<label for="chkDownloadThumb">Thumb</label>
</div>
</fieldset>
<br /> <br />
<br /> <br />
<ul data-role="listview" class="ulForm"> <ul data-role="listview" class="ulForm">

View file

@ -209,6 +209,7 @@
} }
html += '</fieldset>'; html += '</fieldset>';
html += '<div class="fieldDescription">Choose the file formats to save your metadata to.</div>';
$('.metadataSavers', page).html(html).show().trigger('create'); $('.metadataSavers', page).html(html).show().trigger('create');
} }
@ -257,20 +258,42 @@
return; return;
} }
html += '<fieldset data-role="controlgroup">'; html += '<div class="ui-controlgroup-label" style="margin-bottom:0;padding-left:2px;">Preferred Local Metadata:</div>';
html += '<legend>Local Metadata Readers:</legend>'; html += '<ul data-role="listview" data-inset="true" data-mini="true" style="margin-top:.5em;margin-bottom:.5em;">';
for (var i = 0, length = plugins.length; i < length; i++) { for (var i = 0, length = plugins.length; i < length; i++) {
var plugin = plugins[i]; var plugin = plugins[i];
var id = 'chkMetadataLocal' + i; if (i > 0) {
html += '<li data-mini="true" class="localReaderOption" data-pluginname="' + plugin.Name + '">';
html += '<input type="checkbox" name="' + id + '" id="' + id + '" data-mini="true">'; html += '<a href="#" style="font-size:13px;font-weight:normal;">' + plugin.Name + '</a>';
html += '<label for="' + id + '">' + plugin.Name + '</label>';
html += '<a class="btnLocalReaderUp" data-pluginindex="' + i + '" href="#" style="font-size:13px;font-weight:normal;" data-icon="arrow-u">Up</a>';
html += '</li>';
}
else if (plugins.length > 1) {
html += '<li data-mini="true" class="localReaderOption" data-pluginname="' + plugin.Name + '">';
html += '<a href="#" style="font-size:13px;font-weight:normal;">' + plugin.Name + '</a>';
html += '<a class="btnLocalReaderDown" data-pluginindex="' + i + '" href="#" style="font-size:13px;font-weight:normal;" data-icon="arrow-d">Down</a>';
html += '</li>';
}
else {
html += '<li data-mini="true" class="localReaderOption" data-pluginname="' + plugin.Name + '">';
html += plugin.Name;
html += '</li>';
}
} }
html += '</fieldset>'; html += '</ul>';
html += '<div class="fieldDescription">Rank your preferred local metadata sources in order of priority. The first file found will be read.</div>';
$('.metadataReaders', page).html(html).show().trigger('create'); $('.metadataReaders', page).html(html).show().trigger('create');
} }
@ -285,9 +308,9 @@
loadTabs(page, [ loadTabs(page, [
{ name: 'Game', type: 'Game' }, { name: 'Games', type: 'Game' },
{ name: 'Game System', type: 'GameSystem' }, { name: 'Game Systems', type: 'GameSystem' },
{ name: 'Game Genre', type: 'GameGenre' } { name: 'Game Genres', type: 'GameGenre' }
]); ]);
$('.gamesTab', page).addClass('ui-btn-active'); $('.gamesTab', page).addClass('ui-btn-active');
@ -296,9 +319,8 @@
loadTabs(page, [ loadTabs(page, [
{ name: 'Movie', type: 'Movie' }, { name: 'Movies', type: 'Movie' },
{ name: 'Trailer', type: 'Trailer' }, { name: 'Collections', type: 'BoxSet' }
{ name: 'Collection', type: 'BoxSet' }
]); ]);
$('.moviesTab', page).addClass('ui-btn-active'); $('.moviesTab', page).addClass('ui-btn-active');
@ -308,8 +330,8 @@
loadTabs(page, [ loadTabs(page, [
{ name: 'Series', type: 'Series' }, { name: 'Series', type: 'Series' },
{ name: 'Season', type: 'Season' }, { name: 'Seasons', type: 'Season' },
{ name: 'Episode', type: 'Episode' } { name: 'Episodes', type: 'Episode' }
]); ]);
$('.tvTab', page).addClass('ui-btn-active'); $('.tvTab', page).addClass('ui-btn-active');
@ -318,11 +340,11 @@
loadTabs(page, [ loadTabs(page, [
{ name: 'Artist', type: 'MusicArtist' }, { name: 'Artists', type: 'MusicArtist' },
{ name: 'Album', type: 'MusicAlbum' }, { name: 'Albums', type: 'MusicAlbum' },
{ name: 'Song', type: 'Audio' }, { name: 'Songs', type: 'Audio' },
{ name: 'Music Video', type: 'MusicVideo' }, { name: 'Music Videos', type: 'MusicVideo' },
{ name: 'Music Genre', type: 'MusicGenre' } { name: 'Music Genres', type: 'MusicGenre' }
]); ]);
$('.musicTab', page).addClass('ui-btn-active'); $('.musicTab', page).addClass('ui-btn-active');
@ -331,11 +353,12 @@
loadTabs(page, [ loadTabs(page, [
{ name: 'Person', type: 'Person' }, { name: 'People', type: 'Person' },
{ name: 'Genre', type: 'Genre' }, { name: 'Genres', type: 'Genre' },
{ name: 'Studio', type: 'Studio' }, { name: 'Studios', type: 'Studio' },
{ name: 'Book', type: 'Book' }, { name: 'Books', type: 'Book' },
{ name: 'Adult Video', type: 'AdultVideo' } { name: 'Home Videos', type: 'Video' },
{ name: 'Adult Videos', type: 'AdultVideo' }
]); ]);
$('.othersTab', page).addClass('ui-btn-active'); $('.othersTab', page).addClass('ui-btn-active');
@ -350,6 +373,12 @@
}); });
config.LocalMetadataReaders = $('.localReaderOption', form).get().map(function (c) {
return c.getAttribute('data-pluginname');
});
config.ImageOptions = $('.imageType:visible input', form).get().map(function (c) { config.ImageOptions = $('.imageType:visible input', form).get().map(function (c) {