From 2e4314a278e5f19a2daf104f8976c7cfa9189a63 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Sun, 22 Jan 2017 16:09:16 -0500 Subject: [PATCH] update program display titles --- .../emby-webcomponents/.bower.json | 8 ++++---- .../emby-webcomponents/listview/listview.css | 3 +++ .../emby-webcomponents/listview/listview.js | 9 +++++---- .../playback/playbackmanager.js | 16 +++++++++------- dashboard-ui/components/remotecontrol.js | 14 +++----------- dashboard-ui/strings/en-US.json | 2 +- 6 files changed, 25 insertions(+), 27 deletions(-) diff --git a/dashboard-ui/bower_components/emby-webcomponents/.bower.json b/dashboard-ui/bower_components/emby-webcomponents/.bower.json index 52021ae36c..76510765cf 100644 --- a/dashboard-ui/bower_components/emby-webcomponents/.bower.json +++ b/dashboard-ui/bower_components/emby-webcomponents/.bower.json @@ -14,12 +14,12 @@ }, "devDependencies": {}, "ignore": [], - "version": "1.4.480", - "_release": "1.4.480", + "version": "1.4.481", + "_release": "1.4.481", "_resolution": { "type": "version", - "tag": "1.4.480", - "commit": "20243f526641231c0e6911adc7d01fe1368dcc9e" + "tag": "1.4.481", + "commit": "379634e39edbb1c464e99df15fa1dec0773053f4" }, "_source": "https://github.com/MediaBrowser/emby-webcomponents.git", "_target": "^1.2.1", diff --git a/dashboard-ui/bower_components/emby-webcomponents/listview/listview.css b/dashboard-ui/bower_components/emby-webcomponents/listview/listview.css index d54df523d8..fc2a002a77 100644 --- a/dashboard-ui/bower_components/emby-webcomponents/listview/listview.css +++ b/dashboard-ui/bower_components/emby-webcomponents/listview/listview.css @@ -60,6 +60,9 @@ } .listItem-odd { +} + +.listItem-shaded:nth-child(even) { background: #1c1c1c; } diff --git a/dashboard-ui/bower_components/emby-webcomponents/listview/listview.js b/dashboard-ui/bower_components/emby-webcomponents/listview/listview.js index 431fd6bea7..3f7b0f8d4b 100644 --- a/dashboard-ui/bower_components/emby-webcomponents/listview/listview.js +++ b/dashboard-ui/bower_components/emby-webcomponents/listview/listview.js @@ -206,9 +206,10 @@ define(['itemHelper', 'mediaInfo', 'indicators', 'connectionManager', 'layoutMan var cssClass = "listItem"; if (options.highlight !== false) { - if (i % 2 === 1) { - cssClass += ' listItem-odd'; - } + //if (i % 2 === 1) { + // cssClass += ' listItem-odd'; + //} + cssClass += ' listItem-shaded'; } if (clickEntireItem) { @@ -299,7 +300,7 @@ define(['itemHelper', 'mediaInfo', 'indicators', 'connectionManager', 'layoutMan parentTitle = item.SeriesName; } - else if (item.IsSeries) { + else if (item.IsSeries || (item.EpisodeTitle && item.Name)) { parentTitle = item.Name; } } diff --git a/dashboard-ui/bower_components/emby-webcomponents/playback/playbackmanager.js b/dashboard-ui/bower_components/emby-webcomponents/playback/playbackmanager.js index 293ff6d3bc..c433d44359 100644 --- a/dashboard-ui/bower_components/emby-webcomponents/playback/playbackmanager.js +++ b/dashboard-ui/bower_components/emby-webcomponents/playback/playbackmanager.js @@ -1554,7 +1554,7 @@ define(['events', 'datetime', 'appSettings', 'pluginManager', 'userSettings', 'g } } - function playInternal(item, playOptions, callback) { + function playInternal(item, playOptions, onPlaybackStartedFn) { if (item.IsPlaceHolder) { loading.hide(); @@ -1578,16 +1578,16 @@ define(['events', 'datetime', 'appSettings', 'pluginManager', 'userSettings', 'g appSettings.maxStreamingBitrate(bitrate); - return playAfterBitrateDetect(connectionManager, bitrate, item, playOptions).then(callback); + return playAfterBitrateDetect(connectionManager, bitrate, item, playOptions, onPlaybackStartedFn); }, function () { - return playAfterBitrateDetect(connectionManager, appSettings.maxStreamingBitrate(), item, playOptions).then(callback); + return playAfterBitrateDetect(connectionManager, appSettings.maxStreamingBitrate(), item, playOptions, onPlaybackStartedFn); }); } else { - return playAfterBitrateDetect(connectionManager, appSettings.maxStreamingBitrate(), item, playOptions).then(callback); + return playAfterBitrateDetect(connectionManager, appSettings.maxStreamingBitrate(), item, playOptions, onPlaybackStartedFn); } }, function () { @@ -1647,7 +1647,7 @@ define(['events', 'datetime', 'appSettings', 'pluginManager', 'userSettings', 'g }, reject); } - function playAfterBitrateDetect(connectionManager, maxBitrate, item, playOptions) { + function playAfterBitrateDetect(connectionManager, maxBitrate, item, playOptions, onPlaybackStartedFn) { var startPosition = playOptions.startPositionTicks; @@ -1671,8 +1671,9 @@ define(['events', 'datetime', 'appSettings', 'pluginManager', 'userSettings', 'g streamInfo.fullscreen = playOptions.fullscreen; getPlayerData(player).isChangingStream = false; return player.play(streamInfo).then(function () { - onPlaybackStarted(player, streamInfo); loading.hide(); + onPlaybackStartedFn(); + onPlaybackStarted(player, streamInfo); return Promise.resolve(); }); }); @@ -1693,8 +1694,9 @@ define(['events', 'datetime', 'appSettings', 'pluginManager', 'userSettings', 'g getPlayerData(player).maxStreamingBitrate = maxBitrate; return player.play(streamInfo).then(function () { - onPlaybackStarted(player, streamInfo, mediaSource); loading.hide(); + onPlaybackStartedFn(); + onPlaybackStarted(player, streamInfo, mediaSource); return Promise.resolve(); }); }); diff --git a/dashboard-ui/components/remotecontrol.js b/dashboard-ui/components/remotecontrol.js index fe4cb09497..c64486be66 100644 --- a/dashboard-ui/components/remotecontrol.js +++ b/dashboard-ui/components/remotecontrol.js @@ -261,7 +261,6 @@ var currentRuntimeTicks = 0; var self = this; - var playlistNeedsRefresh = true; function toggleRepeat(player) { @@ -491,8 +490,6 @@ dragHandle: true }); - playlistNeedsRefresh = false; - var itemsContainer = context.querySelector('.playlist'); itemsContainer.innerHTML = html; @@ -519,8 +516,6 @@ var player = this; onStateChanged.call(player, e, state); - - loadPlaylist(dlg, player); } function onRepeatModeChange(e) { @@ -534,10 +529,7 @@ var player = this; - playbackManager.getPlayerState(player).then(function (state) { - - onStateChanged.call(player, { type: 'init' }, state); - }); + loadPlaylist(dlg, player); } function onPlaylistItemRemoved(e, info) { @@ -611,7 +603,7 @@ if (player) { events.off(player, 'playbackstart', onPlaybackStart); - events.off(player, 'statechange', onPlaybackStart); + events.off(player, 'statechange', onStateChanged); events.off(player, 'repeatmodechange', onRepeatModeChange); events.off(player, 'playlistitemremove', onPlaylistUpdate); events.off(player, 'playlistitemmove', onPlaylistUpdate); @@ -641,7 +633,7 @@ }); events.on(player, 'playbackstart', onPlaybackStart); - events.on(player, 'statechange', onPlaybackStart); + events.on(player, 'statechange', onStateChanged); events.on(player, 'repeatmodechange', onRepeatModeChange); events.on(player, 'playlistitemremove', onPlaylistItemRemoved); events.on(player, 'playlistitemmove', onPlaylistUpdate); diff --git a/dashboard-ui/strings/en-US.json b/dashboard-ui/strings/en-US.json index 5a11e43c9d..78010c7c50 100644 --- a/dashboard-ui/strings/en-US.json +++ b/dashboard-ui/strings/en-US.json @@ -317,7 +317,7 @@ "LabelFanartApiKey": "Personal api key:", "LabelFanartApiKeyHelp": "Requests to fanart without a personal API key return images that were approved over 7 days ago. With a personal API key that drops to 48 hours and if you are also a fanart VIP member that will further drop to around 10 minutes.", "ExtractChapterImagesHelp": "Extracting chapter images will allow Emby apps to display graphical scene selection menus. The process can be slow, cpu-intensive and may require several gigabytes of space. It runs when videos are discovered, and also as a nightly scheduled task. The schedule is configurable in the scheduled tasks area. It is not recommended to run this task during peak usage hours.", - "LabelMetadataDownloadLanguage": "Preferred metadata download language:", + "LabelMetadataDownloadLanguage": "Preferred metadata language:", "ButtonSignIn": "Sign In", "TitleSignIn": "Sign In", "HeaderPleaseSignIn": "Please sign in",