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

add hover menus to recordings

This commit is contained in:
Luke Pulverenti 2014-01-16 22:13:12 -05:00
parent a0a589b876
commit 4c4c131147
17 changed files with 53 additions and 46 deletions

View file

@ -196,7 +196,7 @@
html += getViewHtml(views[i]);
}
var elem = $('#views', page).html(html);
var elem = $('#views', page).html(html).trigger('create');
if (counts.MovieCount || counts.TrailerCount) {
renderMovieViewImages(elem, userId);

View file

@ -2556,13 +2556,13 @@
buttonCount++;
}
if (currentUser.Configuration.IsAdministrator) {
if (currentUser.Configuration.IsAdministrator && item.Type != "Recording") {
html += '<button type="button" data-mini="true" data-inline="true" data-icon="edit" data-iconpos="notext" title="Edit" onclick="Dashboard.navigate(\'edititemmetadata.html?id=' + item.Id + '\');return false;" style="' + buttonMargin + '">Edit</button>';
buttonCount++;
}
if (!isPortrait || buttonCount < 3) {
html += '<button type="button" data-mini="true" data-inline="true" data-icon="wireless" data-iconpos="notext" title="Play On" class="btnRemoteControl" data-itemid="' + item.Id + '" style="' + buttonMargin + '">Play On</button>';
html += '<button type="button" data-mini="true" data-inline="true" data-icon="wireless" data-iconpos="notext" title="Remote" class="btnRemoteControl" data-itemid="' + item.Id + '" style="' + buttonMargin + '">Remote</button>';
}
html += '</div>';

View file

@ -16,7 +16,7 @@
html += '<a class="desktopHomeLink" href="index.html"><img src="css/images/mblogoicon.png" /></a>';
html += '<button class="viewMenuRemoteControlButton" onclick="RemoteControl.showMenu();" type="button" data-icon="remote" data-inline="true" data-iconpos="notext" title="Remote Control">Remote Control</button>';
html += '<button class="viewMenuRemoteControlButton" onclick="RemoteControl.showMenu();" type="button" data-icon="wireless" data-inline="true" data-iconpos="notext" title="Remote Control">Remote Control</button>';
if (user.Configuration.IsAdministrator) {
html += '<a class="editorMenuLink" href="edititemmetadata.html" data-role="button" data-icon="edit" data-inline="true" data-iconpos="notext" title="Metadata Manager">Metadata Manager</a>';

View file

@ -498,13 +498,6 @@
html += (item.OverviewHtml || item.Overview || '');
html += '</p>';
//html += '<p>';
//html += '<button type="button" data-mini="true" data-inline="true" data-icon="play" data-iconpos="notext">Play</button>';
//html += '<button type="button" data-mini="true" data-inline="true" data-icon="remote" data-iconpos="notext">Play</button>';
//html += '</p>';
html += '</div>';
return html;

View file

@ -35,7 +35,7 @@
html += LibraryBrowser.getPagingHtml(query, result.TotalRecordCount);
$('#items', page).html(html).trigger('create');
$('#items', page).html(html).trigger('create').createPosterItemHoverMenu();
$('.selectPage', page).on('change', function () {
query.StartIndex = (parseInt(this.value) - 1) * query.Limit;

View file

@ -58,7 +58,7 @@
overlayText: true,
coverImage: true
}));
})).createPosterItemHoverMenu();
}
function reload(page) {

View file

@ -127,7 +127,7 @@
overlayText: true,
coverImage: true
}));
})).createPosterItemHoverMenu();
}
function renderSchedule(page, result) {

View file

@ -23,7 +23,7 @@
});
$('.activeProgramItems', page).html(html);
$('.activeProgramItems', page).html(html).createPosterItemHoverMenu();
});
apiClient.getLiveTvRecommendedPrograms({
@ -46,7 +46,7 @@
});
$('.upcomingProgramItems', page).html(html);
$('.upcomingProgramItems', page).html(html).createPosterItemHoverMenu();
});
}

View file

@ -69,7 +69,7 @@
html += '<a href="#" data-rel="back" data-role="button" data-icon="delete" data-iconpos="notext" class="ui-btn-right" data-theme="b">Close</a>';
html += '<div class="ui-bar-b" style="text-align:center;">';
html += '<div style="margin:.5em 0;">Play On</div>';
html += '<div style="margin:.5em 0;">Remote Control</div>';
html += '</div>';
html += '<div style="padding: 1em;">';
@ -90,7 +90,7 @@
html += '<span id="queueButtonContainer" style="display:none;"><button onclick="$(\'#fldPlayCommand\').val(\'PlayLast\');" type="submit" data-icon="plus" data-mini="true" data-inline="true">Queue</button></span>';
html += '<span id="browseButtonContainer" style="display:none;"><button onclick="$(\'#fldPlayCommand\').val(\'Browse\');" type="submit" data-icon="eye" data-mini="true" data-inline="true">View on Screen</button></span>';
html += '<span id="browseButtonContainer" style="display:none;"><button onclick="$(\'#fldPlayCommand\').val(\'Browse\');" type="submit" data-icon="eye" data-mini="true" data-inline="true">View</button></span>';
html += '</p>';
@ -454,31 +454,44 @@
var html = '';
html += '<div style="margin-top:0;">';
html += '<label for="selectCommand">Play:</label>';
html += '<select id="selectCommand" data-mini="true">';
var mediaLabel = item.Type;
html += '<option value="Play" selected>' + mediaLabel + '</label>';
// Default for virtual & IBN types
var playLabel = 'View';
if (item.LocationType != "Virtual") {
if (item.IsFolder) {
playLabel = "Play All";
}
else if (item.MediaType == "Video") {
playLabel = "Play from beginning";
}
else if (item.MediaType) {
playLabel = "Play";
}
}
html += '<option value="Play" selected>' + playLabel + '</label>';
if (item.Chapters && item.Chapters.length) {
html += '<option value="PlayFromChapter">Scene</label>';
html += '<option value="PlayFromChapter">Play from scene</label>';
}
if (item.LocalTrailerCount) {
html += '<option value="Trailer">Trailer</label>';
html += '<option value="Trailer">Play trailer</label>';
}
if (item.SpecialFeatureCount) {
html += '<option value="SpecialFeature">Special feature</label>';
html += '<option value="SpecialFeature">Play special feature</label>';
}
if (options.themeSongs) {
html += '<option value="ThemeSong">Theme song</label>';
html += '<option value="ThemeSong">Play theme song</label>';
}
if (options.themeVideos) {
html += '<option value="ThemeVideo">Theme video</label>';
html += '<option value="ThemeVideo">Play theme video</label>';
}
html += '</select>';
@ -642,7 +655,7 @@
html += '<div class="sessionsPopupContent">';
// Add controls here
html += '<div><label for="selectSession">Select session to control</label>';
html += '<div>';
html += '<select id="selectSession" name="selectSession" data-mini="true"></select></div>';
html += '</div>';
@ -659,24 +672,24 @@
html += '</div>';
html += '<div class="commandsCollapsible" data-role="collapsible" data-collapsed="true" data-mini="true" style="margin-top: 1em;display:none;">';
html += '<h4>Send Command</h4>';
html += '<div>';
html += '<p class="sessionButtons" style="text-align:center;">';
html += '<button class="btnGoHome" type="button" data-icon="home" data-mini="true" data-inline="true">Home</button>';
html += '<button class="btnGoToSettings" type="button" data-icon="gear" data-mini="true" data-inline="true">Settings</button>';
html += '<button class="btnGoHome" type="button" data-icon="home" data-mini="true" data-inline="true">Go Home</button>';
html += '<button class="btnGoToSettings" type="button" data-icon="gear" data-mini="true" data-inline="true">View Settings</button>';
html += '</p>';
html += '<div class="commandsCollapsible" data-role="collapsible" data-collapsed="true" data-mini="true" style="margin-top: 1em;display:none;">';
html += '<h4>Send Message</h4>';
html += '<div>';
html += '<p style="text-align:center;">';
html += '<div><label for="txtMessage">Message text</label></div>';
html += '<input id="txtMessage" name="txtMessage" type="text" />';
html += '<button type="button" data-icon="mail" class="btnSendMessage" data-mini="true">Send</button>';
html += '<button type="button" data-icon="mail" class="btnSendMessage" data-mini="true">Send Message</button>';
html += '</p>';
@ -877,13 +890,11 @@
$('.nothingPlaying', popup).hide();
$('.nowPlaying', popup).hide();
$('.commandsCollapsible', popup).hide();
$('.sessionButtons', popup).hide();
}
else if (session.NowPlayingItem) {
$('.commandsCollapsible', popup).show();
$('.sessionButtons', popup).show();
$('.nothingPlaying', popup).hide();
var elem = $('.nowPlaying', popup).show();
@ -892,7 +903,6 @@
} else {
$('.sessionButtons', popup).show();
$('.commandsCollapsible', popup).show();
$('.nothingPlaying', popup).show();
$('.nowPlaying', popup).hide();

View file

@ -1360,7 +1360,7 @@ $(function () {
footerHtml += '<button onclick="MediaPlayer.showChannelsFlyout();" id="channelsButton" class="mediaButton channelsButton" title="TV Channels" type="button" data-icon="tv" data-iconpos="notext" data-inline="true">TV Channels</button>';
footerHtml += '<div class="mediaFlyoutContainer"><div id="channelsFlyout" style="display:none;" class="mediaPlayerFlyout channelsFlyout"></div></div>';
footerHtml += '<button onclick="MediaPlayer.showSendMediaMenu();" id="sendMediaButton" class="mediaButton sendMediaButton" title="Play On" type="button" data-icon="wireless" data-iconpos="notext" data-inline="true">Play On</button>';
footerHtml += '<button onclick="MediaPlayer.showSendMediaMenu();" id="sendMediaButton" class="mediaButton sendMediaButton" title="Remote" type="button" data-icon="wireless" data-iconpos="notext" data-inline="true">Remote</button>';
footerHtml += '</div>';