better jqm integration

This commit is contained in:
Wouter van Wijk 2013-02-10 23:43:37 +01:00
parent 1327fa0e6c
commit 9aced96d1a
10 changed files with 3570 additions and 301 deletions

File diff suppressed because it is too large Load Diff

View File

@ -18,12 +18,6 @@
color: #fff /*{a-bar-color}*/;
font-weight: bold;
text-shadow: 0 /*{a-bar-shadow-x}*/ -1px /*{a-bar-shadow-y}*/ 0 /*{a-bar-shadow-radius}*/ #000 /*{a-bar-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #3c3c3c /*{a-bar-background-start}*/), to( #111 /*{a-bar-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #3c3c3c /*{a-bar-background-start}*/, #111 /*{a-bar-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #3c3c3c /*{a-bar-background-start}*/, #111 /*{a-bar-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #3c3c3c /*{a-bar-background-start}*/, #111 /*{a-bar-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #3c3c3c /*{a-bar-background-start}*/, #111 /*{a-bar-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #3c3c3c /*{a-bar-background-start}*/, #111 /*{a-bar-background-end}*/);
}
.ui-bar-a,
.ui-bar-a input,
@ -55,12 +49,6 @@
color: #fff /*{a-body-color}*/;
text-shadow: 0 /*{a-body-shadow-x}*/ 1px /*{a-body-shadow-y}*/ 0 /*{a-body-shadow-radius}*/ #111 /*{a-body-shadow-color}*/;
font-weight: normal;
background-image: -webkit-gradient(linear, left top, left bottom, from( #444 /*{a-body-background-start}*/), to( #222 /*{a-body-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #444 /*{a-body-background-start}*/, #222 /*{a-body-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #444 /*{a-body-background-start}*/, #222 /*{a-body-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #444 /*{a-body-background-start}*/, #222 /*{a-body-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #444 /*{a-body-background-start}*/, #222 /*{a-body-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #444 /*{a-body-background-start}*/, #222 /*{a-body-background-end}*/);
}
.ui-overlay-a {
background-image: none;
@ -95,12 +83,6 @@
font-weight: bold;
color: #fff /*{a-bup-color}*/;
text-shadow: 0 /*{a-bup-shadow-x}*/ 1px /*{a-bup-shadow-y}*/ 0 /*{a-bup-shadow-radius}*/ #111 /*{a-bup-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #444 /*{a-bup-background-start}*/), to( #2d2d2d /*{a-bup-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #444 /*{a-bup-background-start}*/, #2d2d2d /*{a-bup-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #444 /*{a-bup-background-start}*/, #2d2d2d /*{a-bup-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #444 /*{a-bup-background-start}*/, #2d2d2d /*{a-bup-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #444 /*{a-bup-background-start}*/, #2d2d2d /*{a-bup-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #444 /*{a-bup-background-start}*/, #2d2d2d /*{a-bup-background-end}*/);
}
.ui-btn-up-a:visited,
.ui-btn-up-a a.ui-link-inherit {
@ -112,12 +94,6 @@
font-weight: bold;
color: #fff /*{a-bhover-color}*/;
text-shadow: 0 /*{a-bhover-shadow-x}*/ 1px /*{a-bhover-shadow-y}*/ 0 /*{a-bhover-shadow-radius}*/ #111 /*{a-bhover-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #555 /*{a-bhover-background-start}*/), to( #383838 /*{a-bhover-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #555 /*{a-bhover-background-start}*/, #383838 /*{a-bhover-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #555 /*{a-bhover-background-start}*/, #383838 /*{a-bhover-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #555 /*{a-bhover-background-start}*/, #383838 /*{a-bhover-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #555 /*{a-bhover-background-start}*/, #383838 /*{a-bhover-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #555 /*{a-bhover-background-start}*/, #383838 /*{a-bhover-background-end}*/);
}
.ui-btn-hover-a:visited,
.ui-btn-hover-a:hover,
@ -130,12 +106,6 @@
font-weight: bold;
color: #fff /*{a-bdown-color}*/;
text-shadow: 0 /*{a-bdown-shadow-x}*/ 1px /*{a-bdown-shadow-y}*/ 0 /*{a-bdown-shadow-radius}*/ #111 /*{a-bdown-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #202020 /*{a-bdown-background-start}*/), to( #2c2c2c /*{a-bdown-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #202020 /*{a-bdown-background-start}*/, #2c2c2c /*{a-bdown-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #202020 /*{a-bdown-background-start}*/, #2c2c2c /*{a-bdown-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #202020 /*{a-bdown-background-start}*/, #2c2c2c /*{a-bdown-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #202020 /*{a-bdown-background-start}*/, #2c2c2c /*{a-bdown-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #202020 /*{a-bdown-background-start}*/, #2c2c2c /*{a-bdown-background-end}*/);
}
.ui-btn-down-a:visited,
.ui-btn-down-a:hover,
@ -156,12 +126,6 @@
color: #fff /*{b-bar-color}*/;
font-weight: bold;
text-shadow: 0 /*{b-bar-shadow-x}*/ 1px /*{b-bar-shadow-y}*/ 0 /*{b-bar-shadow-radius}*/ #3e6790 /*{b-bar-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #6facd5 /*{b-bar-background-start}*/), to( #497bae /*{b-bar-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #6facd5 /*{b-bar-background-start}*/, #497bae /*{b-bar-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #6facd5 /*{b-bar-background-start}*/, #497bae /*{b-bar-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #6facd5 /*{b-bar-background-start}*/, #497bae /*{b-bar-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #6facd5 /*{b-bar-background-start}*/, #497bae /*{b-bar-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #6facd5 /*{b-bar-background-start}*/, #497bae /*{b-bar-background-end}*/);
}
.ui-bar-b,
.ui-bar-b input,
@ -193,12 +157,6 @@
color: #222 /*{b-body-color}*/;
text-shadow: 0 /*{b-body-shadow-x}*/ 1px /*{b-body-shadow-y}*/ 0 /*{b-body-shadow-radius}*/ #fff /*{b-body-shadow-color}*/;
font-weight: normal;
background-image: -webkit-gradient(linear, left top, left bottom, from( #ddd /*{b-body-background-start}*/), to( #ccc /*{b-body-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #ddd /*{b-body-background-start}*/, #ccc /*{b-body-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #ddd /*{b-body-background-start}*/, #ccc /*{b-body-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #ddd /*{b-body-background-start}*/, #ccc /*{b-body-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #ddd /*{b-body-background-start}*/, #ccc /*{b-body-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #ddd /*{b-body-background-start}*/, #ccc /*{b-body-background-end}*/);
}
.ui-overlay-b {
background-image: none;
@ -233,12 +191,6 @@
font-weight: bold;
color: #fff /*{b-bup-color}*/;
text-shadow: 0 /*{b-bup-shadow-x}*/ 1px /*{b-bup-shadow-y}*/ 0 /*{b-bup-shadow-radius}*/ #194b7e /*{b-bup-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #5f9cc5 /*{b-bup-background-start}*/), to( #396b9e /*{b-bup-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #5f9cc5 /*{b-bup-background-start}*/, #396b9e /*{b-bup-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #5f9cc5 /*{b-bup-background-start}*/, #396b9e /*{b-bup-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #5f9cc5 /*{b-bup-background-start}*/, #396b9e /*{b-bup-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #5f9cc5 /*{b-bup-background-start}*/, #396b9e /*{b-bup-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #5f9cc5 /*{b-bup-background-start}*/, #396b9e /*{b-bup-background-end}*/);
}
.ui-btn-up-b:visited,
.ui-btn-up-b a.ui-link-inherit {
@ -250,12 +202,6 @@
font-weight: bold;
color: #fff /*{b-bhover-color}*/;
text-shadow: 0 /*{b-bhover-shadow-x}*/ 1px /*{b-bhover-shadow-y}*/ 0 /*{b-bhover-shadow-radius}*/ #194b7e /*{b-bhover-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #6facd5 /*{b-bhover-background-start}*/), to( #4272a4 /*{b-bhover-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #6facd5 /*{b-bhover-background-start}*/, #4272a4 /*{b-bhover-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #6facd5 /*{b-bhover-background-start}*/, #4272a4 /*{b-bhover-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #6facd5 /*{b-bhover-background-start}*/, #4272a4 /*{b-bhover-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #6facd5 /*{b-bhover-background-start}*/, #4272a4 /*{b-bhover-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #6facd5 /*{b-bhover-background-start}*/, #4272a4 /*{b-bhover-background-end}*/);
}
.ui-btn-hover-b:visited,
.ui-btn-hover-b:hover,
@ -268,12 +214,6 @@
font-weight: bold;
color: #fff /*{b-bdown-color}*/;
text-shadow: 0 /*{b-bdown-shadow-x}*/ 1px /*{b-bdown-shadow-y}*/ 0 /*{b-bdown-shadow-radius}*/ #194b7e /*{b-bdown-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #295b8e /*{b-bdown-background-start}*/), to( #3e79b5 /*{b-bdown-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #295b8e /*{b-bdown-background-start}*/, #3e79b5 /*{b-bdown-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #295b8e /*{b-bdown-background-start}*/, #3e79b5 /*{b-bdown-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #295b8e /*{b-bdown-background-start}*/, #3e79b5 /*{b-bdown-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #295b8e /*{b-bdown-background-start}*/, #3e79b5 /*{b-bdown-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #295b8e /*{b-bdown-background-start}*/, #3e79b5 /*{b-bdown-background-end}*/);
}
.ui-btn-down-b:visited,
.ui-btn-down-b:hover,
@ -294,12 +234,6 @@
color: #3e3e3e /*{c-bar-color}*/;
font-weight: bold;
text-shadow: 0 /*{c-bar-shadow-x}*/ 1px /*{c-bar-shadow-y}*/ 0 /*{c-bar-shadow-radius}*/ #fff /*{c-bar-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #f0f0f0 /*{c-bar-background-start}*/), to( #ddd /*{c-bar-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #f0f0f0 /*{c-bar-background-start}*/, #ddd /*{c-bar-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #f0f0f0 /*{c-bar-background-start}*/, #ddd /*{c-bar-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #f0f0f0 /*{c-bar-background-start}*/, #ddd /*{c-bar-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #f0f0f0 /*{c-bar-background-start}*/, #ddd /*{c-bar-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #f0f0f0 /*{c-bar-background-start}*/, #ddd /*{c-bar-background-end}*/);
}
.ui-bar-c .ui-link-inherit {
color: #3e3e3e /*{c-bar-color}*/;
@ -330,12 +264,6 @@
color: #333 /*{c-body-color}*/;
text-shadow: 0 /*{c-body-shadow-x}*/ 1px /*{c-body-shadow-y}*/ 0 /*{c-body-shadow-radius}*/ #fff /*{c-body-shadow-color}*/;
background: #f9f9f9 /*{c-body-background-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #f9f9f9 /*{c-body-background-start}*/), to( #eee /*{c-body-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #f9f9f9 /*{c-body-background-start}*/, #eee /*{c-body-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #f9f9f9 /*{c-body-background-start}*/, #eee /*{c-body-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #f9f9f9 /*{c-body-background-start}*/, #eee /*{c-body-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #f9f9f9 /*{c-body-background-start}*/, #eee /*{c-body-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #f9f9f9 /*{c-body-background-start}*/, #eee /*{c-body-background-end}*/);
}
.ui-overlay-c {
background-image: none;
@ -370,12 +298,6 @@
font-weight: bold;
color: #222 /*{c-bup-color}*/;
text-shadow: 0 /*{c-bup-shadow-x}*/ 1px /*{c-bup-shadow-y}*/ 0 /*{c-bup-shadow-radius}*/ #fff /*{c-bup-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #fff /*{c-bup-background-start}*/), to( #f1f1f1 /*{c-bup-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #fff /*{c-bup-background-start}*/, #f1f1f1 /*{c-bup-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #fff /*{c-bup-background-start}*/, #f1f1f1 /*{c-bup-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #fff /*{c-bup-background-start}*/, #f1f1f1 /*{c-bup-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #fff /*{c-bup-background-start}*/, #f1f1f1 /*{c-bup-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #fff /*{c-bup-background-start}*/, #f1f1f1 /*{c-bup-background-end}*/);
}
.ui-btn-up-c:visited,
.ui-btn-up-c a.ui-link-inherit {
@ -387,12 +309,6 @@
font-weight: bold;
color: #222 /*{c-bhover-color}*/;
text-shadow: 0 /*{c-bhover-shadow-x}*/ 1px /*{c-bhover-shadow-y}*/ 0 /*{c-bhover-shadow-radius}*/ #fff /*{c-bhover-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #f6f6f6 /*{c-bhover-background-start}*/), to( #e0e0e0 /*{c-bhover-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #f6f6f6 /*{c-bhover-background-start}*/, #e0e0e0 /*{c-bhover-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #f6f6f6 /*{c-bhover-background-start}*/, #e0e0e0 /*{c-bhover-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #f6f6f6 /*{c-bhover-background-start}*/, #e0e0e0 /*{c-bhover-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #f6f6f6 /*{c-bhover-background-start}*/, #e0e0e0 /*{c-bhover-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #f6f6f6 /*{c-bhover-background-start}*/, #e0e0e0 /*{c-bhover-background-end}*/);
}
.ui-btn-hover-c:visited,
.ui-btn-hover-c:hover,
@ -405,12 +321,6 @@
font-weight: bold;
color: #222 /*{c-bdown-color}*/;
text-shadow: 0 /*{c-bdown-shadow-x}*/ 1px /*{c-bdown-shadow-y}*/ 0 /*{c-bdown-shadow-radius}*/ #fff /*{c-bdown-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #d0d0d0 /*{c-bdown-background-start}*/), to( #dfdfdf /*{c-bdown-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #d0d0d0 /*{c-bdown-background-start}*/, #dfdfdf /*{c-bdown-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #d0d0d0 /*{c-bdown-background-start}*/, #dfdfdf /*{c-bdown-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #d0d0d0 /*{c-bdown-background-start}*/, #dfdfdf /*{c-bdown-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #d0d0d0 /*{c-bdown-background-start}*/, #dfdfdf /*{c-bdown-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #d0d0d0 /*{c-bdown-background-start}*/, #dfdfdf /*{c-bdown-background-end}*/);
}
.ui-btn-down-c:visited,
.ui-btn-down-c:hover,
@ -431,12 +341,6 @@
color: #333 /*{d-bar-color}*/;
font-weight: bold;
text-shadow: 0 /*{d-bar-shadow-x}*/ 1px /*{d-bar-shadow-y}*/ 0 /*{d-bar-shadow-radius}*/ #eee /*{d-bar-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #ddd /*{d-bar-background-start}*/), to( #bbb /*{d-bar-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #ddd /*{d-bar-background-start}*/, #bbb /*{d-bar-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #ddd /*{d-bar-background-start}*/, #bbb /*{d-bar-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #ddd /*{d-bar-background-start}*/, #bbb /*{d-bar-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #ddd /*{d-bar-background-start}*/, #bbb /*{d-bar-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #ddd /*{d-bar-background-start}*/, #bbb /*{d-bar-background-end}*/);
}
.ui-bar-d,
.ui-bar-d input,
@ -467,12 +371,6 @@
color: #333 /*{d-body-color}*/;
text-shadow: 0 /*{d-body-shadow-x}*/ 1px /*{d-body-shadow-y}*/ 0 /*{d-body-shadow-radius}*/ #fff /*{d-body-shadow-color}*/;
background: #fff /*{d-body-background-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #fff /*{d-body-background-start}*/), to( #fff /*{d-body-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #fff /*{d-body-background-start}*/, #fff /*{d-body-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #fff /*{d-body-background-start}*/, #fff /*{d-body-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #fff /*{d-body-background-start}*/, #fff /*{d-body-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #fff /*{d-body-background-start}*/, #fff /*{d-body-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #fff /*{d-body-background-start}*/, #fff /*{d-body-background-end}*/);
}
.ui-overlay-d {
background-image: none;
@ -507,12 +405,6 @@
font-weight: bold;
color: #333 /*{d-bup-color}*/;
text-shadow: 0 /*{d-bup-shadow-x}*/ 1px /*{d-bup-shadow-y}*/ 0 /*{d-bup-shadow-radius}*/ #fff /*{d-bup-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #fafafa /*{d-bup-background-start}*/), to( #f6f6f6 /*{d-bup-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #fafafa /*{d-bup-background-start}*/, #f6f6f6 /*{d-bup-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #fafafa /*{d-bup-background-start}*/, #f6f6f6 /*{d-bup-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #fafafa /*{d-bup-background-start}*/, #f6f6f6 /*{d-bup-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #fafafa /*{d-bup-background-start}*/, #f6f6f6 /*{d-bup-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #fafafa /*{d-bup-background-start}*/, #f6f6f6 /*{d-bup-background-end}*/);
}
.ui-btn-up-d:visited,
.ui-btn-up-d a.ui-link-inherit {
@ -525,12 +417,6 @@
color: #333 /*{d-bhover-color}*/;
cursor: pointer;
text-shadow: 0 /*{d-bhover-shadow-x}*/ 1px /*{d-bhover-shadow-y}*/ 0 /*{d-bhover-shadow-radius}*/ #fff /*{d-bhover-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #eee /*{d-bhover-background-start}*/), to( #fff /*{d-bhover-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #eee /*{d-bhover-background-start}*/, #fff /*{d-bhover-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #eee /*{d-bhover-background-start}*/, #fff /*{d-bhover-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #eee /*{d-bhover-background-start}*/, #fff /*{d-bhover-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #eee /*{d-bhover-background-start}*/, #fff /*{d-bhover-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #eee /*{d-bhover-background-start}*/, #fff /*{d-bhover-background-end}*/);
}
.ui-btn-hover-d:visited,
.ui-btn-hover-d:hover,
@ -543,12 +429,6 @@
font-weight: bold;
color: #333 /*{d-bdown-color}*/;
text-shadow: 0 /*{d-bdown-shadow-x}*/ 1px /*{d-bdown-shadow-y}*/ 0 /*{d-bdown-shadow-radius}*/ #fff /*{d-bdown-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #e5e5e5 /*{d-bdown-background-start}*/), to( #f2f2f2 /*{d-bdown-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #e5e5e5 /*{d-bdown-background-start}*/, #f2f2f2 /*{d-bdown-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #e5e5e5 /*{d-bdown-background-start}*/, #f2f2f2 /*{d-bdown-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #e5e5e5 /*{d-bdown-background-start}*/, #f2f2f2 /*{d-bdown-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #e5e5e5 /*{d-bdown-background-start}*/, #f2f2f2 /*{d-bdown-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #e5e5e5 /*{d-bdown-background-start}*/, #f2f2f2 /*{d-bdown-background-end}*/);
}
.ui-btn-down-d:visited,
.ui-btn-down-d:hover,
@ -569,12 +449,6 @@
color: #333 /*{e-bar-color}*/;
font-weight: bold;
text-shadow: 0 /*{e-bar-shadow-x}*/ 1px /*{e-bar-shadow-y}*/ 0 /*{e-bar-shadow-radius}*/ #fff /*{e-bar-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #fceda7 /*{e-bar-background-start}*/), to( #fbef7e /*{e-bar-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #fceda7 /*{e-bar-background-start}*/, #fbef7e /*{e-bar-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #fceda7 /*{e-bar-background-start}*/, #fbef7e /*{e-bar-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #fceda7 /*{e-bar-background-start}*/, #fbef7e /*{e-bar-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #fceda7 /*{e-bar-background-start}*/, #fbef7e /*{e-bar-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #fceda7 /*{e-bar-background-start}*/, #fbef7e /*{e-bar-background-end}*/);
}
.ui-bar-e,
.ui-bar-e input,
@ -605,12 +479,6 @@
color: #222 /*{e-body-color}*/;
text-shadow: 0 /*{e-body-shadow-x}*/ 1px /*{e-body-shadow-y}*/ 0 /*{e-body-shadow-radius}*/ #fff /*{e-body-shadow-color}*/;
background: #fff9df /*{e-body-background-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #fffadf /*{e-body-background-start}*/), to( #fff3a5 /*{e-body-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #fffadf /*{e-body-background-start}*/, #fff3a5 /*{e-body-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #fffadf /*{e-body-background-start}*/, #fff3a5 /*{e-body-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #fffadf /*{e-body-background-start}*/, #fff3a5 /*{e-body-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #fffadf /*{e-body-background-start}*/, #fff3a5 /*{e-body-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #fffadf /*{e-body-background-start}*/, #fff3a5 /*{e-body-background-end}*/);
}
.ui-overlay-e {
background-image: none;
@ -645,12 +513,6 @@
font-weight: bold;
color: #222 /*{e-bup-color}*/;
text-shadow: 0 /*{e-bup-shadow-x}*/ 1px /*{e-bup-shadow-y}*/ 0 /*{e-bup-shadow-radius}*/ #fff /*{e-bup-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #ffefaa /*{e-bup-background-start}*/), to( #ffe155 /*{e-bup-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #ffefaa /*{e-bup-background-start}*/, #ffe155 /*{e-bup-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #ffefaa /*{e-bup-background-start}*/, #ffe155 /*{e-bup-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #ffefaa /*{e-bup-background-start}*/, #ffe155 /*{e-bup-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #ffefaa /*{e-bup-background-start}*/, #ffe155 /*{e-bup-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #ffefaa /*{e-bup-background-start}*/, #ffe155 /*{e-bup-background-end}*/);
}
.ui-btn-up-e:visited,
.ui-btn-up-e a.ui-link-inherit {
@ -662,12 +524,6 @@
font-weight: bold;
color: #111 /*{e-bhover-color}*/;
text-shadow: 0 /*{e-bhover-shadow-x}*/ 1px /*{e-bhover-shadow-y}*/ 0 /*{e-bhover-shadow-radius}*/ #fff /*{e-bhover-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #fff5ba /*{e-bhover-background-start}*/), to( #fbdd52 /*{e-bhover-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #fff5ba /*{e-bhover-background-start}*/, #fbdd52 /*{e-bhover-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #fff5ba /*{e-bhover-background-start}*/, #fbdd52 /*{e-bhover-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #fff5ba /*{e-bhover-background-start}*/, #fbdd52 /*{e-bhover-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #fff5ba /*{e-bhover-background-start}*/, #fbdd52 /*{e-bhover-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #fff5ba /*{e-bhover-background-start}*/, #fbdd52 /*{e-bhover-background-end}*/);
}
.ui-btn-hover-e:visited,
.ui-btn-hover-e:hover,
@ -680,12 +536,6 @@
font-weight: bold;
color: #111 /*{e-bdown-color}*/;
text-shadow: 0 /*{e-bdown-shadow-x}*/ 1px /*{e-bdown-shadow-y}*/ 0 /*{e-bdown-shadow-radius}*/ #fff /*{e-bdown-shadow-color}*/;
background-image: -webkit-gradient(linear, left top, left bottom, from( #f8d94c /*{e-bdown-background-start}*/), to( #fadb4e /*{e-bdown-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #f8d94c /*{e-bdown-background-start}*/, #fadb4e /*{e-bdown-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #f8d94c /*{e-bdown-background-start}*/, #fadb4e /*{e-bdown-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #f8d94c /*{e-bdown-background-start}*/, #fadb4e /*{e-bdown-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #f8d94c /*{e-bdown-background-start}*/, #fadb4e /*{e-bdown-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #f8d94c /*{e-bdown-background-start}*/, #fadb4e /*{e-bdown-background-end}*/);
}
.ui-btn-down-e:visited,
.ui-btn-down-e:hover,
@ -714,12 +564,6 @@ a.ui-link-inherit {
cursor: pointer;
text-shadow: 0 /*{global-active-shadow-x}*/ 1px /*{global-active-shadow-y}*/ 0 /*{global-active-shadow-radius}*/ #3373a5 /*{global-active-shadow-color}*/;
text-decoration: none;
background-image: -webkit-gradient(linear, left top, left bottom, from( #5393c5 /*{global-active-background-start}*/), to( #6facd5 /*{global-active-background-end}*/)); /* Saf4+, Chrome */
background-image: -webkit-linear-gradient( #5393c5 /*{global-active-background-start}*/, #6facd5 /*{global-active-background-end}*/); /* Chrome 10+, Saf5.1+ */
background-image: -moz-linear-gradient( #5393c5 /*{global-active-background-start}*/, #6facd5 /*{global-active-background-end}*/); /* FF3.6 */
background-image: -ms-linear-gradient( #5393c5 /*{global-active-background-start}*/, #6facd5 /*{global-active-background-end}*/); /* IE10 */
background-image: -o-linear-gradient( #5393c5 /*{global-active-background-start}*/, #6facd5 /*{global-active-background-end}*/); /* Opera 11.10+ */
background-image: linear-gradient( #5393c5 /*{global-active-background-start}*/, #6facd5 /*{global-active-background-end}*/);
font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
}
.ui-btn-active:visited,

View File

@ -5,26 +5,40 @@
/* Responsive stuff */
@media all and (min-width: 50.1em) {
.pl-breakpoint.ui-grid-a .ui-block-a { width: 32.95%; }
.pl-breakpoint.ui-grid-a .ui-block-b { width: 65.92%; }
.pl-breakpoint.ui-grid-a .ui-block-a { clear: left; }
.header-breakpoint.ui-grid-b .ui-block-a { width: 19.95%; }
.header-breakpoint.ui-grid-b .ui-block-b { width: 39.92%; }
.header-breakpoint.ui-grid-b .ui-block-c { width: 39.92%; }
.pl-breakpoint.ui-grid-a .ui-block-a { clear: left; }
.pl-breakpoint.ui-grid-a .ui-block-a {
width: 32.95%;
}
.pl-breakpoint.ui-grid-a .ui-block-b {
width: 66%;
}
.pl-breakpoint.ui-grid-a .ui-block-a {
clear: left;
}
.header-breakpoint.ui-grid-b .ui-block-a {
width: 19.95%;
}
.header-breakpoint.ui-grid-b .ui-block-b {
width: 39.92%;
}
.header-breakpoint.ui-grid-b .ui-block-c {
width: 39.92%;
}
.pl-breakpoint.ui-grid-a .ui-block-a {
clear: left;
}
#playlisttablediv {
margin-left: 10px;
}
}
@media all and (max-width: 50em) {
.pl-breakpoint .ui-block-a,
.pl-breakpoint .ui-block-b {
width: 100%;
float:none;
.pl-breakpoint .ui-block-a, .pl-breakpoint .ui-block-b {
width: 100%;
float: none;
}
.header-breakpoint .ui-block-a,
.header-breakpoint .ui-block-b,
.header-breakpoint .ui-block-c {
width: 100%;
float:none;
.header-breakpoint .ui-block-a, .header-breakpoint .ui-block-b, .header-breakpoint .ui-block-c {
width: 100%;
float: none;
}
}
@ -38,17 +52,16 @@
margin-top: 5px;
margin-bottom: 5px;
}
/*
.ui-slider-track {
margin-left: 38px;
margin-right: 35px;
}
.ui-mobile .ui-page .ui-slider-input,
.ui-mobile .ui-dialog .ui-slider-input {
display : none !important;
.ui-mobile .ui-page .ui-slider-input, .ui-mobile .ui-dialog .ui-slider-input {
display: none !important;
}
*/
#songelapsed, #songlength {
font-size: 10px;
margin-top: 12px;
@ -69,7 +82,7 @@
#previmg {
margin-top: -100px;
}
}
#btplaypause a img {
margin-top: 5px;
@ -79,7 +92,6 @@
margin-right: 5px;
}
/* Song information */
#infoname {
@ -103,14 +115,14 @@
margin: 2px;
}
/* div */
/* div */
body {
/* padding-top: 80px;
/* background-image:url('../iages/Chrisdesign_LP_Guitar_black.web.png');
background-attachment: fixed;
background-repeat:no-repeat;
background-position:right;
*/
/* padding-top: 80px;
/* background-image:url('../iages/Chrisdesign_LP_Guitar_black.web.png');
background-attachment: fixed;
background-repeat:no-repeat;
background-position:right;
*/
}
.nobreak, .btsquare {
@ -141,14 +153,30 @@ body {
display: none;
}
/*.currenttrack {
font-weight: bold;
.currenttrack {
background-image: url('../img/icons/play_alt_16x16.png');
background-repeat: no-repeat;
padding-left: 20px;
}*/
#popupTrackName, #popupAlbumName, .popupArtistName {
font-style:oblique;
background-color: #fff;
background-position: 4px center;
padding-left: 10px;
}
#modalartist {
color: #444;
font-size: 14px;
}
#modalartist a {
color: #444;
text-decoration: none;
}
#infoartist a {
color: #eee;
text-decoration: none;
}
#popupTrackName, #popupAlbumName, .popupArtistName {
font-style: oblique;
}

View File

@ -39,12 +39,14 @@
<br/>
<div id="modalalbum"></div>
<div class="">
<a href="#" onclick="doRandom(); return false"><img src="images/icons/loop_alt2_16x14.png" alt="" id="randombt" /></a>
<p><a href="#" onclick="doRandom(); return false"><img src="images/icons/loop_alt2_16x14.png" alt="" id="randombt" /></a>
&nbsp; <a href="#" onclick="doRepeat(); return false"><img src="images/icons/reload_12x14.png" id="repeatbt" alt="" /></a>
<br/>
<br/>
<a href="#" onclick="doMute(); return false;"><img id="mutebt" src="images/icons/volume_16x12.png" alt="" /></a>
<input id="volumeslider" data-mini="true" type="range" min="0" value="0" max="100" onchange="doVolume(this.value);" class="nobreak" />
<label for="volumeslider" class="ui-hidden-accessible">Volume</label>
<input id="volumeslider" name="volumeslider" data-mini="true" type="range" min="0" value="0" max="100" onchange="doVolume(this.value);" class="nobreak" />
</p>
</div>
<div class="">
<a href="#" class="" >Close</a>
@ -52,7 +54,7 @@
</div>
<div data-role="popup" data-transition="pop" id="popupTracks">
<div data-role="collapsible-set" data-theme="c" data-content-theme="d" style="margin:0;">
<div data-role="collapsible-set">
<ul data-role="listview" data-inset="true" data-icon="false" id="popupTracksLv" style="min-width:210px;">
<!-- <li data-role="divider">
Track
@ -96,15 +98,15 @@
<div id="slidercontainer" class="ui-block-c">
<span id="songelapsed" class="pull-left"> 0:00 </span>
<span id="songlength" class="pull-right"> 0:00 </span>
<label for="trackslider" class="ui-hidden-accessible">Position</label>
<input id="trackslider" name="trackslider" data-mini="true" type="range" onmousedown="pauseTimer();" onchange="doSeekPos(this.value);" class="nobreak" />
</div>
</div><!-- /header -->
<div data-role="content" id="playlistspane" class="pane ui-grid-a pl-breakpoint">
<div class="ui-block-a">
<ul id="playlistslist" data-icon="false" data-role="listview" data-filter="true"></ul>
<ul id="playlistslist" data-icon="false" data-inset="true" data-role="listview" data-filter="true"></ul>
</div>
<div class="ui-block-b" id="playlisttablediv">
<ul data-role="listview" data-icon="false" id="playlisttable" data-inset="true" data-filter="true"></ul>
@ -116,7 +118,6 @@
<div data-role="content" class="pane" id="currentpane">
<h4>Play Queue</h4>
<ul data-role="listview" data-icon="false" data-inset="true" id="currenttable"></ul>
<img src="images/loader.gif" id="currentloader" class= "loader" />
</div>

View File

@ -2,7 +2,7 @@
* play an uri from a trackslist or the current playlist
*********************************************************/
function playTrack() {
//function playtrack(uri, playlisturi) {
//function playtrack(uri, playlisturi) {
playlisturi = $('#popupTracks').data("list");
uri = $('#popupTracks').data("track");
//console.log(uri);
@ -12,9 +12,9 @@ function playTrack() {
switchContent('current', uri);
var tracks = getTracksFromUri(playlisturi);
if (tracks) {
$(CURRENT_PLAYLIST_TABLE).empty();
mopidy.tracklist.clear();
mopidy.tracklist.add(tracks);
$(CURRENT_PLAYLIST_TABLE).empty();
} else {
tracks = currentplaylist;
}
@ -34,6 +34,9 @@ function playTrack() {
return false;
}
/**********************
* Buttons
*/
/* Toggle state of play button */
function setPlayState(nwplay) {
@ -55,21 +58,30 @@ function doPlayPause() {
setPlayState(!play);
}
function doMute() {
//only emit the event, not the status
if (muteVolume == -1) {
$("#mutebt").attr('src', 'images/icons/volume_mute_24x18.png');
muteVolume = currentVolume;
mopidy.playback.setVolume(0).then();
function doPrevious() {
// if position > 2 seconds -> go to begin, else go to previous track
if (currentposition > 2000) {
doSeekPos(0);
} else {
$("#mutebt").attr('src', 'images/icons/volume_24x18.png');
mopidy.playback.setVolume(muteVolume).then();
muteVolume = -1;
mopidy.playback.previous();
}
}
function doNext() {
mopidy.playback.next();
}
function backbt() {
$(CURRENT_PLAYLIST_TABLE).listview('refresh');
//history.back();
return false;
}
/***************
* Options
*/
function setRepeat(nwrepeat) {
if (repeat == nwrepeat) {
return
@ -94,19 +106,6 @@ function setRandom(nwrandom) {
random = nwrandom;
}
function doPrevious() {
// if position > 2 seconds -> go to begin, else go to previous track
if (currentposition > 2000) {
doSeekPos(0);
} else {
mopidy.playback.previous();
}
}
function doNext() {
mopidy.playback.next();
}
function doRandom() {
if (random == false) {
mopidy.playback.setRandom(true);
@ -125,17 +124,12 @@ function doRepeat() {
setRepeat(!repeat);
}
function doVolume(value) {
if (!initgui) {
console.log('volume: ' + value);
mopidy.playback.setVolume(value);
}
}
/*********************
* Track Slider
*********************/
function doSeekPos(value) {
var val = $("#trackslider").val();
console.log('value: ' + value);
console.log('val: ' + val);
val = Math.round(val);
if (!initgui) {
//set timer to not trigger it too much
@ -146,6 +140,7 @@ function doSeekPos(value) {
}
function triggerPos(val) {
console.log(val);
if (mopidy) {
mopidy.playback.seek(val);
}
@ -163,11 +158,34 @@ function setPosition(pos) {
$("#songelapsed").html(timeFromSeconds(currentposition / 1000));
}
/********************
* Volume
*/
function setVolume(value) {
$("#volumeslider").attr("value", value);
var oldval = initgui;
initgui = true;
$("#volumeslider").val(value).slider('refresh');
initgui = oldval;
}
function backbt() {
history.back();
return false;
function doVolume(value) {
if (!initgui) {
console.log('volume: ' + value);
mopidy.playback.setVolume(value);
}
}
function doMute() {
//only emit the event, not the status
if (muteVolume == -1) {
$("#mutebt").attr('src', 'images/icons/volume_mute_24x18.png');
muteVolume = currentVolume;
mopidy.playback.setVolume(0).then();
} else {
$("#mutebt").attr('src', 'images/icons/volume_24x18.png');
mopidy.playback.setVolume(muteVolume).then();
muteVolume = -1;
}
}

View File

@ -44,6 +44,17 @@ SEARCH_ALL_TABLE = '#allresulttable';
SEARCH_ALBUM_TABLE = '#albumresulttable';
SEARCH_ARTIST_TABLE = '#artistresulttable';
SEARCH_TRACK_TABLE = '#trackresulttable';
TRACK_TIMER = 500;
/*******
*
*/
function scrollToTracklist() {
var divtop = $("#playlisttablediv").offset().top - 15;
$('body,html').animate({
scrollTop : divtop
}, 250);
}
//A hack to find the name of the first artist of a playlist. this is not yet returned by mopidy
//does not work wel with multiple artists of course
@ -70,7 +81,7 @@ function getAlbum(pl) {
function playlisttotable(pl, table, uri) {
var tmp = '';
$(table).html('');
// console.log(pl);
var child = '';
for (var i = 0; i < pl.length; i++) {
/* var child = '<li><a href="#" class="name" id="' + pl[i].uri + '"><h2>' + pl[i].name + "</h2></a>";
@ -92,31 +103,31 @@ function playlisttotable(pl, table, uri) {
tmp += child;
*/
popupData[pl[i].uri] = pl[i];
child ='<li><a href="#" onclick="return popupTracks(\'' + uri + '\',\'' + pl[i].uri + '\');">';
child = '<li id="' + pl[i].uri + '"><a href="#" onclick="return popupTracks(\'' + uri + '\',\'' + pl[i].uri + '\');">';
child += '<h1>' + pl[i].name + "</h1>";
child += '<p>';
child += '<span style="float: right;">' + timeFromSeconds(pl[i].length / 1000) + '</span>';
// <span class="ui-icon ui-icon-arrow-r ui-icon-shadow">&nbsp;</span>
for (var j = 0; j < pl[i].artists.length; j++) {
child += pl[i].artists[j].name;
child += (j == pl[i].artists.length - 1) ? '' : ' / ';
//stop after 3
if (j > 2) {
child += '...';
break;
}
}
child += '</p>';
child += '<h1>' + pl[i].name + "</h1>";
child += ' / <em>' + pl[i].album.name + '</em></p>';
child += '<p>' + pl[i].album.name + '</p>';
// child += '<p>' + pl[i].album.name + '</p>';
child += '</a></li>';
tmp += child;
};
// console.log(tmp);
$(table).html(tmp);
$(table).attr('data', uri);
// console.log(tmp);
//create (for new tables)
// $(table).listview().trigger("create");
//refresh
@ -130,7 +141,8 @@ function albumtrackstotable(pl, table, uri) {
for (var i = 0; i < pl.length; i++) {
popupData[pl[i].uri] = pl[i];
child = '<li><a href="#" onclick="return popupTracks(\'' + uri + '\',\'' + pl[i].uri + '\');">';
child += '<span style="float: right;"><p>' + timeFromSeconds(pl[i].length / 1000) + '</p></span><h1>' + pl[i].name + '</h1></a></li>';
child += '<p style="float:right; display: inline;">' + timeFromSeconds(pl[i].length / 1000) +
'</p><h1>' + pl[i].name + '</h1></a></li>';
tmp += child;
};
$(table).html(tmp);

View File

@ -3,11 +3,9 @@
* do- functions interact with the server
* show- functions do both
*/
function showAlbumPopup() {
uri = $('#popupTracks').data("track");
showAlbum(popupData[uri].album.uri);
}
/********************
* Song Info Sreen
********************/
function resetSong() {
pauseTimer();
setPlayState(false);
@ -21,7 +19,6 @@ function resetSong() {
}
function expandSonginfo() {
}
function resizeSonginfo() {
@ -49,7 +46,6 @@ function resizeSonginfo() {
}
function setSongInfo(data) {
artistshtml = '';
artiststext = '';
songname = data.name;
@ -77,20 +73,27 @@ function setSongInfo(data) {
}
$("#modalartist").html(arttmp + ': ' + artistshtml);
$("#trackslider").attr("min", 0);
$("#trackslider").attr("max", data.length);
$("#songlength").html(timeFromSeconds(data.length / 1000));
resizeSonginfo();
$('#currenttable li').each(function() {
$('#currenttable li').each(
function() {
//console.log(this.className);
this.className = "name";
$(this).removeClass("currenttrack");
if (this.id == data.uri) {
this.className += ' currenttrack';
$(this).addClass('currenttrack');
}
});
}
/***************
* display popup
* @param {Object} listuri
* @param {Object} trackuri
*/
function popupTracks (listuri, trackuri) {
console.log('list: ' + listuri + ', track: ' + trackuri);
$('#popupTrackName').html(popupData[trackuri].name);
@ -117,28 +120,14 @@ function popupTracks (listuri, trackuri) {
return false;
}
function scrollToTracklist() {
var divtop = $("#playlisttablediv").offset().top - 15;
$('body,html').animate({
scrollTop : divtop
}, 250);
}
//update everything as if reloaded
function updateStatusOfAll() {
mopidy.playback.getCurrentTrack().then(processCurrenttrack, console.error);
mopidy.playback.getTimePosition().then(processCurrentposition, console.error);
mopidy.playback.getState().then(processPlaystate, console.error);
mopidy.playback.getRepeat().then(processRepeat, console.error);
mopidy.playback.getRandom().then(processRandom, console.error);
mopidy.playback.getVolume().then(processVolume, console.error);
//TODO check offline?
function showAlbumPopup() {
uri = $('#popupTracks').data("track");
showAlbum(popupData[uri].album.uri);
}
/*****************
* Modal dialogs
*****************/
function showLoading(on) {
if (on) {
$.mobile.loading('show', {
@ -165,6 +154,10 @@ function showOffline(on) {
}
}
/*********************
* initialize sockets
*********************/
function initSocketevents() {
mopidy.on("state:online", function() {
showOffline(false);
@ -225,30 +218,25 @@ function initSocketevents() {
});
}
function switchContent(divid, uri) {
var hash = divid;
if (uri) {
hash += "?" + uri;
}
// $.mobile.changePage("#" + hash);
location.hash = "#" + hash;
}
/*******
* Track timer
*/
//timer function to update interface
function updateTimer() {
currentposition += 100;
currentposition += TRACK_TIMER;
setPosition(currentposition);
// $("#songelapsed").html(timeFromSeconds(currentposition / 1000));
}
function resumeTimer() {
pauseTimer();
posTimer = setInterval(updateTimer, 100);
posTimer = setInterval(updateTimer, TRACK_TIMER);
}
function initTimer() {
pauseTimer();
setPosition(0);
// setPosition(0);
resumeTimer();
}
@ -256,7 +244,9 @@ function pauseTimer() {
clearInterval(posTimer);
}
/**********************
* initialize software
**********************/
//$(document).ready(function() {
$(document).bind("pageinit", function() {
@ -327,5 +317,31 @@ $(document).bind("pageinit", function() {
// console.log(arguments);
});
//update gui every x seconds from mopdidy
// setInterval(updateStatusOfAll, 5000);
setInterval(updateStatusOfAll, 5000);
});
/************************
* diverse
************************/
function switchContent(divid, uri) {
var hash = divid;
if (uri) {
hash += "?" + uri;
}
// $.mobile.changePage("#" + hash);
location.hash = "#" + hash;
}
//update everything as if reloaded
function updateStatusOfAll() {
mopidy.playback.getCurrentTrack().then(processCurrenttrack, console.error);
mopidy.playback.getTimePosition().then(processCurrentposition, console.error);
mopidy.playback.getState().then(processPlaystate, console.error);
mopidy.playback.getRepeat().then(processRepeat, console.error);
mopidy.playback.getRandom().then(processRandom, console.error);
mopidy.playback.getVolume().then(processVolume, console.error);
//TODO check offline?
}

View File

@ -9358,7 +9358,7 @@ $.widget( "mobile.slider", $.mobile.widget, {
var pxStep, percent,
control = this.element,
isInput = this.isToggleSwitch,
isInput = !this.isToggleSwitch,
optionElements = isInput ? [] : control.find( "option" ),
min = isInput ? parseFloat( control.attr( "min" ) ) : 0,
max = isInput ? parseFloat( control.attr( "max" ) ) : optionElements.length - 1,
@ -9387,11 +9387,6 @@ $.widget( "mobile.slider", $.mobile.widget, {
val = isInput ? parseFloat( control.val() || 0 ) : control[0].selectedIndex;
}
percent = ( parseFloat( val ) - min ) / ( max - min ) * 100;
console.log('pc: ' + percent);
console.log('val: ' + val);
console.log('max: ' + max);
console.log('min: ' + min);
}
if ( isNaN( percent ) ) {

View File

@ -1,6 +1,6 @@
/*********************************
* Search
*/
*********************************/
function searchPressed(key) {
var value = $('#searchinput').val();
switchContent('search');
@ -90,12 +90,10 @@ function toggleSearch() {
/*********************************
* Playlists
*/
*********************************/
function getPlaylists() {
/********************************************************
* get playlists without tracks
********************************************************/
// get playlists without tracks
mopidy.playlists.getPlaylists(false).then(processGetPlaylists, console.error);
}

View File

@ -95,7 +95,7 @@ function processGetTracklist(resultArr) {
*********************************************************/
function processCurrentPlaylist(resultArr) {
currentplaylist = resultArr;
playlisttotable(resultArr, CURRENT_PLAYLIST_TABLE);
playlisttotable(resultArr, CURRENT_PLAYLIST_TABLE);
mopidy.playback.getCurrentTrack().then(processCurrenttrack, console.error);
}