diff --git a/dashboard-ui/css/search.css b/dashboard-ui/css/search.css index 00fe0ac8e6..437f685d11 100644 --- a/dashboard-ui/css/search.css +++ b/dashboard-ui/css/search.css @@ -2,18 +2,8 @@ width: 250px; } - .searchPanel + .ui-panel-dismiss { - right: 250px; - } - -@media all and (min-width: 600px) { - .searchPanel { - width: 300px; - } - - .searchPanel + .ui-panel-dismiss { - right: 300px; - } +.searchPanelModelOpen { + right: 250px!important; } .searchHints { diff --git a/dashboard-ui/css/site.css b/dashboard-ui/css/site.css index 59574947e2..5d6e1e59b8 100644 --- a/dashboard-ui/css/site.css +++ b/dashboard-ui/css/site.css @@ -953,6 +953,20 @@ progress { box-shadow: 0 0 20px 1px #38c; } +.sessionNowPlayingTime { + color: #fff; + position: absolute; + right: 10px; + bottom: 15px; +} + +.sessionNowPlayingStreamInfo { + color: #fff; + position: absolute; + left: 10px; + top: 10px; +} + @media all and (max-width: 1000px) { .activeSession { diff --git a/dashboard-ui/scripts/dashboardpage.js b/dashboard-ui/scripts/dashboardpage.js index 9b1a1559dc..74d90ace16 100644 --- a/dashboard-ui/scripts/dashboardpage.js +++ b/dashboard-ui/scripts/dashboardpage.js @@ -280,7 +280,11 @@ html += ''; - html += '
'; + html += '
'; + + html += '
' + DashboardPage.getSessionNowPlayingStreamInfo(connection) + '
'; + html += '
' + DashboardPage.getSessionNowPlayingTime(connection) + '
'; + html += '
'; html += ''; @@ -291,6 +295,50 @@ $('.deadSession', parentElement).remove(); }, + getSessionNowPlayingStreamInfo: function (session) { + + var html = ''; + + html += '
'; + + if (session.PlayState.PlayMethod == 'Transcode') { + html += 'Transcoding'; + } + else if (session.PlayState.PlayMethod == 'DirectStream') { + html += 'Direct Streaming'; + } + else if (session.PlayState.PlayMethod == 'DirectPlay') { + html += 'Direct Playing'; + } + + html += '
'; + + return html; + }, + + getSessionNowPlayingTime: function (session) { + + var html = ''; + + if (session.PlayState.PositionTicks) { + html += Dashboard.getDisplayTime(session.PlayState.PositionTicks); + } else { + html += '--:--:--'; + } + + html += ' / '; + + var nowPlayingItem = session.NowPlayingItem; + + if (nowPlayingItem && nowPlayingItem.RunTimeTicks) { + html += Dashboard.getDisplayTime(nowPlayingItem.RunTimeTicks); + } else { + html += '--:--:--'; + } + + return html; + }, + getAppSecondaryText: function (session) { return session.ApplicationVersion; @@ -405,6 +453,9 @@ row.removeClass('playingSession'); } + $('.sessionNowPlayingStreamInfo', row).html(DashboardPage.getSessionNowPlayingStreamInfo(session)); + $('.sessionNowPlayingTime', row).html(DashboardPage.getSessionNowPlayingTime(session)); + $('.sessionUserName', row).html(DashboardPage.getUsersHtml(session)); $('.sessionAppSecondaryText', row).html(DashboardPage.getAppSecondaryText(session)); @@ -416,7 +467,7 @@ nowPlayingInfoElem.html(nowPlayingName.html); nowPlayingInfoElem.attr('data-imgsrc', nowPlayingName.image || ''); } - + if (nowPlayingItem && nowPlayingItem.RunTimeTicks) { var position = session.PlayState.PositionTicks || 0; diff --git a/dashboard-ui/scripts/medialibrarypage.js b/dashboard-ui/scripts/medialibrarypage.js index 06240399de..445c7a190c 100644 --- a/dashboard-ui/scripts/medialibrarypage.js +++ b/dashboard-ui/scripts/medialibrarypage.js @@ -73,7 +73,7 @@ })[0]; - typeName = typeName ? typeName.name : "General or mixed content"; + typeName = typeName ? typeName.name : "Mixed movies & tv"; html += '

Folder type: ' + typeName + '

'; diff --git a/dashboard-ui/scripts/nowplayingbar.js b/dashboard-ui/scripts/nowplayingbar.js index 27432acfce..9b5ce2fcfc 100644 --- a/dashboard-ui/scripts/nowplayingbar.js +++ b/dashboard-ui/scripts/nowplayingbar.js @@ -62,9 +62,6 @@ if (currentPlayer) { currentPlayer.unMute(); - - $(this).hide(); - $('.muteButton', elem).show(); } }); @@ -72,9 +69,6 @@ if (currentPlayer) { currentPlayer.mute(); - - $(this).hide(); - $('.unmuteButton', elem).show(); } }); @@ -89,9 +83,6 @@ if (currentPlayer) { currentPlayer.pause(); - - $(this).hide(); - $('.unpauseButton', elem).show(); } }); @@ -99,9 +90,6 @@ if (currentPlayer) { currentPlayer.unpause(); - - $(this).hide(); - $('.pauseButton', elem).show(); } }); @@ -163,6 +151,14 @@ return elem; } + + function showButton(button) { + button.removeClass('hide'); + } + + function hideButton(button) { + button.addClass('hide'); + } function updatePlayerState(state) { @@ -203,24 +199,24 @@ if (state.isMuted) { - muteButton.hide(); - unmuteButton.show(); + hideButton(muteButton); + showButton(unmuteButton); } else { - muteButton.show(); - unmuteButton.hide(); + showButton(muteButton); + hideButton(unmuteButton); } if (state.isPaused) { - pauseButton.hide(); - unpauseButton.show(); + hideButton(pauseButton); + showButton(unpauseButton); } else { - pauseButton.show(); - unpauseButton.hide(); + showButton(pauseButton); + hideButton(unpauseButton); } if (!isVolumeSliderActive) { @@ -320,6 +316,8 @@ function onPlaybackStart(e, state) { + console.log('nowplaying event: ' + e.type); + var player = this; player.beginPlayerUpdates(); @@ -343,6 +341,7 @@ function onPlaybackStopped(e, state) { + console.log('nowplaying event: ' + e.type); var player = this; player.endPlayerUpdates(); @@ -352,6 +351,7 @@ function onStateChanged(e, state) { + //console.log('nowplaying event: ' + e.type); var player = this; if (player.isDefaultPlayer && state.mediaType == 'Video') { @@ -385,7 +385,7 @@ player.beginPlayerUpdates(); } - onStateChanged.call(player, null, state); + onStateChanged.call(player, {type: 'init'}, state); }); $(player).on('playbackstart.nowplayingbar', onPlaybackStart) diff --git a/dashboard-ui/scripts/search.js b/dashboard-ui/scripts/search.js index 1622648319..4f67793d23 100644 --- a/dashboard-ui/scripts/search.js +++ b/dashboard-ui/scripts/search.js @@ -230,7 +230,7 @@ $(page).append(html); - panel = $('#searchPanel', page).panel({}).trigger('create'); + panel = $('#searchPanel', page).panel({}).panel('option', 'classes.modalOpen', 'searchPanelModelOpen ui-panel-dismiss-open').trigger('create'); $('#txtSearch', panel).on("keyup", function (e) { diff --git a/dashboard-ui/supporterkey.html b/dashboard-ui/supporterkey.html index 495301581f..65cf7f8af3 100644 --- a/dashboard-ui/supporterkey.html +++ b/dashboard-ui/supporterkey.html @@ -18,23 +18,24 @@
- +
- +
- Enter your supporter key to start enjoying additional benefits the community has developed for Media Browser. MB3 keys only. + ${LabelSupporterKeyHelp}
- +
- +
@@ -48,16 +49,16 @@
-

Lost Key

+

${HeaderForgotKey}

- + -
The email address that was used to purchase the key.
+
${LabelSupporterEmailAddress}

- +

@@ -65,31 +66,31 @@
-

Multiple Key Linking

+

${HeaderMultipleKeyLinking}

- If you have more than one supporter key, use this form to link the old key's registrations with your new one. + ${MultipleKeyLinkingHelp}

- +
- The current email address to which your new key was sent. + ${LabelCurrentEmailAddressHelp}

- +

- +

- +