diff --git a/dashboard-ui/components/remotecontrol.js b/dashboard-ui/components/remotecontrol.js
index 323f625858..c4bdb1d877 100644
--- a/dashboard-ui/components/remotecontrol.js
+++ b/dashboard-ui/components/remotecontrol.js
@@ -1,167 +1,5 @@
define(['browser', 'paper-fab', 'paper-tabs', 'paper-slider', 'paper-icon-button'], function (browser) {
- function getAnimatedPagesHtml() {
-
- var html = '';
-
- html += '
\
- \
-
\
-
\
-
\
-
\
-
\
-
\
-
\
-
\
-
\
-
\
-
\
-
${HeaderSendMessage}
\
-
\
-
\
-
\
-
${HeaderTypeText}
\
-
\
-
\
-
\
-
\
- \
-';
-
- return html;
- }
-
- function getHeaderHtml() {
-
- var html = '';
-
- var position = AppInfo.enableNowPlayingPageBottomTabs ? 'absolute' : 'relative;';
-
- html += '';
- html += '
';
-
- html += '
';
- html += '
';
- html += '
';
- //html += '
';
- html += '
';
- html += '
';
-
- html += '\
- ';
-
- return html;
- }
-
- function getTabsHtml() {
-
- var html = '';
-
- html += '\
- ${TabNowPlaying}\
- ${TabControls}\
- ${TabPlaylist}\
- ';
-
- return html;
- }
-
function showSlideshowMenu(context) {
require(['scripts/slideshow'], function () {
SlideShow.showMenu();
@@ -748,6 +586,8 @@
MediaController.currentPlaylistIndex(index);
loadPlaylist(context);
+ e.preventDefault();
+ e.stopPropagation();
return false;
}
var lnkRemoveFromPlaylist = parentWithClass(e.target, 'lnkRemoveFromPlaylist');
@@ -757,6 +597,8 @@
MediaController.removeFromPlaylist(index);
loadPlaylist(context);
+ e.preventDefault();
+ e.stopPropagation();
return false;
}
@@ -766,6 +608,8 @@
MediaController.currentPlaylistIndex(info.index);
+ e.preventDefault();
+ e.stopPropagation();
return false;
}
}
@@ -990,6 +834,7 @@
tabs.classList.add('bottom');
tabs.alignBottom = true;
+ tabs.noSlide = true;
tabs.addEventListener('iron-select', function (e) {
@@ -1037,28 +882,30 @@
var selected = tab == '#playlist' ? 2 : 0;
- if (AppInfo.enableNowPlayingPageBottomTabs) {
- context.querySelector('paper-tabs').selected = selected;
- } else {
+ var delay = browser.animate ? 0 : 1000;
- showTab(selected);
- }
+ // hack alert. doing this because the neon elements don't seem to be initialized yet
+ setTimeout(function () {
+
+ if (AppInfo.enableNowPlayingPageBottomTabs) {
+ context.querySelector('paper-tabs').selected = selected;
+ } else {
+
+ showTab(selected);
+ }
+ }, delay);
updateCastIcon(context);
}
self.init = function (context) {
- var html = '';
-
dlg = context;
- html += '';
- html += Globalize.translateDocument(getHeaderHtml());
- html += Globalize.translateDocument(getAnimatedPagesHtml());
- html += Globalize.translateDocument(getTabsHtml());
- html += '
';
- dlg.innerHTML = html;
+ if (!AppInfo.enableNowPlayingPageBottomTabs) {
+ context.querySelector('.btnExitRemoteControl').style.position = 'relative';
+ context.querySelector('.topRightContainer').style.position = 'relative';
+ }
init(dlg);
};
diff --git a/dashboard-ui/nowplaying.html b/dashboard-ui/nowplaying.html
index 7f04edfc00..f8d38aedc7 100644
--- a/dashboard-ui/nowplaying.html
+++ b/dashboard-ui/nowplaying.html
@@ -7,7 +7,142 @@
-
+
+
+
+
+
+
+
+
+
+
${HeaderSendMessage}
+
+
+
+
+
+
+
+ ${TabNowPlaying}
+ ${TabControls}
+ ${TabPlaylist}
+