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

Enable movie format ribbons

Per-user configuration to enable movie format ribbons
This commit is contained in:
Tim Hobbs 2014-03-13 06:17:02 -07:00
parent a2336fb26c
commit 55eb408d18
4 changed files with 15 additions and 2 deletions

View file

@ -338,7 +338,6 @@
}
/********************/
.ribbon-wrapper {
display: none;
width: 50px;
height: 50px;
overflow: hidden;

View file

@ -674,6 +674,13 @@
}
}
var enableRibbons = false;
var user = Dashboard.getCurrentUser().done(function (data) {
if (data.Configuration) {
enableRibbons = data.Configuration.DisplayMovieFormatRibbons;
}
});
for (var i = 0, length = items.length; i < length; i++) {
var item = items[i];
@ -878,7 +885,7 @@
html += '<a data-itemid="' + item.Id + '" class="' + cssClass + '" href="' + LibraryBrowser.getHref(item, options.context) + '">';
// Ribbon
if (options.context == "movies") {
if (item.MediaType == "Video" && enableRibbons) {
// This would be much better if specified in the json payload
// Another nice thing to have in the payload would be 720 vs 1080
// Then, rather than "HD" it could display the specific HD format

View file

@ -27,6 +27,8 @@
$('#chkManageLiveTv', page).checked(user.Configuration.EnableLiveTvManagement || false).checkboxradio("refresh");
$('#chkEnableLiveTvAccess', page).checked(user.Configuration.EnableLiveTvAccess || false).checkboxradio("refresh");
$('#chkDisplayMovieFormatRibbons', page).checked(user.Configuration.DisplayMovieFormatRibbons || false).checkboxradio("refresh");
Dashboard.hideLoadingMsg();
}
@ -59,6 +61,7 @@
user.Configuration.EnableLiveTvManagement = $('#chkManageLiveTv', page).checked();
user.Configuration.EnableMediaPlayback = $('#chkEnableMediaPlayback', page).checked();
user.Configuration.EnableLiveTvAccess = $('#chkEnableLiveTvAccess', page).checked();
user.Configuration.DisplayMovieFormatRibbons = $('#chkDisplayMovieFormatRibbons', page).checked();
var userId = getParameterByName("userId");

View file

@ -44,6 +44,10 @@
<input type="checkbox" id="chkEnableRemoteControlOtherUsers" name="chkEnableRemoteControlOtherUsers" data-mini="true" />
<label for="chkEnableRemoteControlOtherUsers">Allow this user to remote control other users</label>
</div>
<div>
<input type="checkbox" id="chkDisplayMovieFormatRibbons" name="chkDisplayMovieFormatRibbons" data-mini="true" />
<label for="chkDisplayMovieFormatRibbons">Display movie format ribbons</label>
</div>
<br />
</div>
<div id="accessControlDiv" style="display: none" data-role="collapsible">