diff options
author | Alib <aliboba@free.fr> | 2010-03-23 13:11:09 +0100 |
---|---|---|
committer | Alib <aliboba@free.fr> | 2010-03-23 13:11:09 +0100 |
commit | 4f4dd73b19eec0d199684f2f7e6a5be9b3554881 (patch) | |
tree | 2ed6f61533e69bf50d084310c6664c3bae43470d | |
parent | cd85d3d8558516ca387a619f12a2d6278ae8af27 (diff) | |
download | istreamdev-4f4dd73b19eec0d199684f2f7e6a5be9b3554881.tar.gz istreamdev-4f4dd73b19eec0d199684f2f7e6a5be9b3554881.tar.bz2 |
now VDR VIdeo & Audio home menu appears depending of streamdev_server,video_path & audio_path value in config file.
-rw-r--r-- | index.html | 20 | ||||
-rw-r--r-- | js/istreamdev.js | 38 |
2 files changed, 40 insertions, 18 deletions
@@ -3,8 +3,8 @@ <head> <meta charset="UTF-8" /> <title>iStreamdev</title> - <style type="text/css" media="screen">@import "min/?b=css&f=jqtouch.css,theme.css,istreamdev.css,spinningwheel.css";</style> - <script src="min/?b=js&f=jquery-1.4.2.min.js,jqtouch.js,jqtouch.transitions.js,istreamdev.js,functions.js,spinningwheel.js" type="text/javascript" charset="utf-8"></script> + <style type="text/css" media="screen">@import "min/?b=./css&f=jqtouch.css,theme.css,istreamdev.css,spinningwheel.css";</style> + <script src="min/?b=./js&f=jquery-1.4.2.min.js,jqtouch.js,jqtouch.transitions.js,istreamdev.js,functions.js,spinningwheel.js" type="text/javascript" charset="utf-8"></script> </head> <body> <div id="loader"></div> @@ -16,19 +16,9 @@ <h1>HOME</h1> </div> <ul class="rounded" id="runningsessions"> + <li><span class="menutitle">SESSIONS</span></li> + <li>Checking running session</li> </ul> - <ul class="rounded"> - <li><span class="menutitle">VDR</span></li> - <li class="arrow"><a id="categories_but" href="#"><img class="menuicon" src="img/tv.png" /><span class="menuname">Watch TV</span></a></li> - <li class="arrow"><a id="recording_but" href="#"><img class="menuicon" src="img/record.png" /><span class="menuname">Recordings</span></a></li> - <li class="arrow"><a id="timers_but" href="#"><img class="menuicon" src="img/timers.png" /><span class="menuname">Timers</span></a></li> - <li class="arrow"><a id="epg_but" href="#epg"><img class="menuicon" src="img/epg.png" /><span class="menuname">Program Guide</span></a></li> - </ul> - <ul class="rounded"> - <li><span class="menutitle">FILES</span></li> - <li class="arrow"><a id="video_but" href="#"><img class="menuicon" src="img/video.png" /><span class="menuname">Video</span></a></li> - <li class="arrow"><a id="audio_but" href="#"><img class="menuicon" src="img/audio.png" /><span class="menuname">Audio</span></a></li> - </ul> </div> <!----------------------------------/ HOME SCREEN ----------------------------------> <!---------------------------------- CHAN CATEGORY SCREEN ----------------------------------> @@ -262,4 +252,4 @@ <!------------------------------------ /EPG -------------------------------------------> </div> </body> -</html> +</html>
\ No newline at end of file diff --git a/js/istreamdev.js b/js/istreamdev.js index c27e99c..d080bd7 100644 --- a/js/istreamdev.js +++ b/js/istreamdev.js @@ -56,8 +56,40 @@ $.getJSON("bin/backend.php", rec_path = data.rec_path;
video_path = data.video_path;
audio_path = data.audio_path;
+ if (streamdev_server != "") {
+ addVdr();
}
- );
+ if ( video_path != "" ) {
+ addVideofiles();
+ }
+ if ( audio_path != "" ) {
+ addAudiofiles();
+ }
+});
+
+function addVdr() {
+ vdrmenu = ' <ul class="rounded">\n<li><span class="menutitle">VDR</span></li>\n';
+ vdrmenu += ' <li class="arrow"><a id="categories_but" href="#"><img class="menuicon" src="img/tv.png" /><span class="menuname">Watch TV</span></a></li>';
+ vdrmenu += ' <li class="arrow"><a id="recording_but" href="#"><img class="menuicon" src="img/record.png" /><span class="menuname">Recordings</span></a></li>';
+ vdrmenu += ' <li class="arrow"><a id="timers_but" href="#"><img class="menuicon" src="img/timers.png" /><span class="menuname">Timers</span></a></li>';
+ vdrmenu += ' <li class="arrow"><a id="epg_but" href="#epg"><img class="menuicon" src="img/epg.png" /><span class="menuname">Program Guide</span></a></li>\n</ul>';
+ $('#home #runningsessions').after(vdrmenu);
+}
+function addVideofiles() {
+ videomenu = '<li class="arrow"><a id="video_but" href="#"><img class="menuicon" src="img/video.png" /><span class="menuname">Video</span></a></li>';
+ if ( $('#home #filemenu').length == 0 ) {
+ $('#home').append('<ul class="rounded" id="filemenu"><li><span class="menutitle">FILES</span></li></ul>');
+ }
+ $('#home #filemenu').append(videomenu);
+}
+
+function addAudiofiles() {
+ audiomenu = '<li class="arrow"><a id="audio_but" href="#"><img class="menuicon" src="img/audio.png" /><span class="menuname">Audio</span></a></li>';
+ if ( $('#home #filemenu').length == 0 ) {
+ $('#home').append('<ul class="rounded" id="filemenu"><li><span class="menutitle">FILES</span></li></ul>');
+ }
+ $('#home #filemenu').append(audiomenu);
+}
//Goto home
$('#home_but').tap(function(event) {
@@ -217,12 +249,12 @@ $('#runningsessions li a').tap(function(event) { // Get Active broadcast & encoding sessions
function getRunningSessions() {
var dataString = "action=getRunningSessions";
- $('#home #runningsessions').html('');
+ $('#home #runningsessions').html('<li><span class="menutitle">SESSIONS</span></li>\n<li>Checking running session</li>');
//Json call to get category array
$.getJSON("bin/backend.php",
dataString,
function(data){
- $('#home #runningsessions').append('<li><span class="menutitle">SESSIONS</span></li>');
+ $('#home #runningsessions').html('<li><span class="menutitle">SESSIONS</span></li>');
if ( data.broadcast.length >= 1 ) {
$.each(data.broadcast, function(i,broadcast){
session = broadcast.session;
|