-
Notifications
You must be signed in to change notification settings - Fork 5
/
index.html
172 lines (172 loc) · 6.28 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
<!doctype html>
<html>
<head>
<title>Acoustics</title>
<meta charset="utf-8" />
<!-- CSS sheets -->
<link rel="stylesheet" href="www-data/jquery-ui-1.8.6.custom.css" />
<link rel="stylesheet" id="structure" href="www-data/acoustics2.css" />
<link rel="stylesheet" id="theme" href="www-data/dark-theme.css" />
<!-- Default favicon -->
<link rel="shortcut icon" href="www-data/images/ui2/favicon.ico" />
<!-- JS includes -->
<script src="www-data/jquery.min.js"></script>
<script src="www-data/jquery-ui-1.8.6.custom.min.js"></script>
<script src="www-data/jquery.tablesorter.min.js"></script>
<script src="www-data/jquery.address-1.3.min.js"></script>
<script src="www-data/jquery.reflection.js"></script>
<script src="www-data/jquery.favicon.js"></script>
<script src="www-data/jquery.sortElements.js"></script>
<script src="www-data/ContentFlow/contentflow.js"></script>
<!-- JS core -->
<script src="www-data/acoustics2.js"></script>
<!-- The following tags are for iOS devices -->
<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=no;"/>
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black" />
<link rel="apple-touch-icon-precomposed" href="www-data/icons/ios/57.png" />
<link rel="apple-touch-icon-precomposed" sizes="72x72" href="www-data/icons/ios/72.png" />
<link rel="apple-touch-icon-precomposed" sizes="114x114" href="www-data/icons/ios/114.png" />
<script>
function selectAndGo(player_id) {
$.getJSON(
getPath_("mode=change_player;player_id="+player_id),
function(data) {
window.location = "index2.html";
}
);
}
function refreshPlayers() {
$.getJSON(
getPath('mode=global_status'),
function (json) {
if (json.player_names.length > 1) {
$("#select-player-list").html("");
for (i in json.player_names) {
var player = $("<td width=\"auto\"></td>");
player.append("<a href=\"javascript:selectAndGo('" + json.player_names[i] + "');\"><span>" + json.player_names[i] + "</span></a>");
if (json.players[json.player_names[i]]) {
$("a", player).append("<br /><img height='70' width='70' />");
$("a img", player).attr("src", newArtUrl(json.players[json.player_names[i]].song.song_id,70));
$("a", player).append("<br />" + json.players[json.player_names[i]].song.title);
$("a", player).append("<br />" + json.players[json.player_names[i]].song.artist);
} else {
$("a", player).append("<br /><img height='70' src='www-data/images/ui2/buttons/volume-up.svg' />");
$("a", player).append("<br />Nothing playing.");
$("a", player).append("<br /> ");
}
$("#select-player-list").append(player);
}
} else {
window.location = "index2.html";
}
}
);
}
function initialize() {
refreshTimer = setInterval('refreshPlayers()', 15000);
refreshPlayers();
}
</script>
<style>
.select-player-table tr td a {
display: block;
background-color: #555;
padding: 8px;
border: 1px solid #222;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
font-size: 14px;
color: #fff;
}
.select-player-table tr td a:hover {
background-color: #888 !important;
color: #222;
text-decoration: none !important;
}
.select-player-table tr td a span {
font-size: 18px;
}
</style>
</head>
<body onload="initialize();">
<div id="header-bar">
<div id="header-bar-logo">
<img src="www-data/images/ui2/amp_logo_new.svg" alt="Acoustics" />
</div>
<div id="header-bar-spacer"> </div>
<div id="header-bar-menu">
<div id="header-bar-menu-container">
<ul id="header-bar-menu-list">
<li><a href="#" id="header-bar-menu-songs">Landing Page</a></li>
<li>
<ul id="header-bar-menu-players-dropdown" class="header-bar-menu-dropdown">
<li><a href="#">Room A</a></li>
<li><a href="#">Room B</a></li>
</ul>
</li>
<li><a id="header-bar-menu-players" class="header-bar-menu-root" href="#">Players</a></li>
</ul>
</div>
</div>
<div id="header-bar-user">
<span><a href="javascript:toggleTheme()">☆</a></span>
<span id="header-bar-user-message"><a href="javascript:login()">login</a></span> <span id="user-name"></span>
</div>
</div>
<div id="main-content">
<div id="search-results" class="panel panel-left">
<div id="search-results-toolbar" class="toolbar">
<ul id="search-results-toolbar-list" class="toolbar-list">
<li id="search-results-panel-title" style="width: 100%; text-align: center;"><span>Welcome to Acoustics!</span></li>
</ul>
</div>
<div id="search-results-container" class="container">
<div style="padding: 48px; text-align: center;">
<img src="www-data/images/ui2/amp_logo_new.svg" height="100" alt="Acoustics" /><br />
<br /><br />
<table class="select-player-table" style="width: 70%; margin-left: auto; margin-right: auto; table-layout: fixed;">
<tr id="select-player-list">
<td>Loading...</td>
</tr>
</table>
<table class="select-player-table" style="width: 70%; margin-left: auto; margin-right: auto; table-layout: fixed;">
<tr>
<td id="select-player-skip">
<a href="index2.html">
<span>Skip</span><br />
<img src="www-data/images/ui2/buttons/next.svg" width="70" height="70" /><br />
(use your last player and continue)
</a>
</td>
</tr>
<tr>
<td id="select-player-skip">
<a href="index_old.html">
<span>Legacy Interface</span><br /><br />
(Unsupported)
</a>
</td>
</tr>
</table>
</div>
</div>
<div id="search-results-statusbar" class="statusbar">
<div id="search-results-blank-status"></div>
</div>
</div>
</div>
<div id="message-box-dimmer">
</div>
<div id="message-box">
<div id="message-box-inner">
<h1 id="message-box-title">Title</h1>
<span id="message-box-message">Content</span>
</div>
<div id="message-box-close">
<a class="control-button button-link" href="javascript:closeMessageBox();">Okay</a>
</div>
</div>
</body>
</html>