diff options
author | Andreas Mair <amair.sob@googlemail.com> | 2005-06-22 14:42:18 +0200 |
---|---|---|
committer | Andreas Mair <amair.sob@googlemail.com> | 2005-06-22 14:42:18 +0200 |
commit | 1f33deeae237bdcc4281de03d268528d4a09edd3 (patch) | |
tree | ba27f73a162201dc1f33a83cdb77ca724ab22fa8 /template/default/infobox.js | |
parent | d6922e850779c4ff9d8bcbcef9842cf333eb8638 (diff) | |
download | vdradmin-am-0.97-am3.3rc.tar.gz vdradmin-am-0.97-am3.3rc.tar.bz2 |
2005-06-22: 0.97-am3.3rcv0.97-am3.3rc
- Updated all help messages.
- Added beautified tooltips in timer_list. PLEASE COMMENT!!!
- Changed saving of AutoTimer patterns: ":" -> "|" and "|" -> "\|".
- Added support for user.css for overwriting style.css (Must be located in /etc/vdradmin/). See user.css.example. PLEASE COMMENT ON THIS!!!
- Removed obsolete files (e.g. images).
- Merged style.css and navi.css.
- Reworked templates so that they use a lot of CSS (Tested using Konqueror 3.3.2 and Firefox 1.0.4).
- Fixed programming timers with special summary when using EPG_DIRECT (timer didn't get programmed) (Thanks to HolgerAusB for giving vital hints).
- Allow browsers to cache all files VDRAdmin sends, except "text/html". This should speed up VDRAdmin but changing the skin or css needs a "shift reload".
- Added support for VDR v1.3.25's info.vdr (Submitted by vejoun).
- Use localized date formates.
- Now using "video/x-mpegurl" MIME type instead of "audio/x-mpegurl" for streaming (Suggested by stefan.h).
- Added patches supplied by stefan.h:
-> using EPG's subtitle when found for AutoTimer else " " (that's the VDR way).
-> New config option VDRVFAT to find recordings if VDR has been compiled with or without VFAT define.
- Fixed calling reccmds on recordings in subdirs, manual recordings (@rectitle) and repeating timer's recordings without episode title.
- Fixed streaming of manual recordings (@rectitle) and repeating timer's recordings without episode title.
- VDRAdmin-AM now uses the required charsets setting in templates, so no need to write "&xyz;" things in .po files.
- Reworked templates to make better use of CSS (for example: timeline colours can be set by style.css).
- EPG_PRUNE now is the number of channels to fetch from VDR (had been one too less before).
- Added "install.sh" and "uninstall.sh" ("./install.sh -h" for help) (Requested by several people).
- Made "name" columns in lists wrapping again (Reported by vejoun).
- Deleting a single recording works again (Reported by vejoun).
- Fixed streaming of recordings in subdirs (Reported by vejoun).
- Added missing gray sign on deactivated AutoTimers (Reported by vejoun).
Diffstat (limited to 'template/default/infobox.js')
-rw-r--r-- | template/default/infobox.js | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/template/default/infobox.js b/template/default/infobox.js new file mode 100644 index 0000000..590ffbd --- /dev/null +++ b/template/default/infobox.js @@ -0,0 +1,83 @@ +//
+// Bubblehelp infoboxes, (C) 2002 Klaus Knopper <infobox@knopper.net>
+// You can copy/modify and distribute this code under the conditions
+// of the GNU GENERAL PUBLIC LICENSE Version 2.
+//
+var IWIDTH=250 // Tip box width
+var ns4 // Are we using Netscape4?
+var ie4 // Are we using Internet Explorer Version 4?
+var ie5 // Are we using Internet Explorer Version 5 and up?
+var kon // Are we using KDE Konqueror?
+var x,y,winW,winH // Current help position and main window size
+var idiv=null // Pointer to infodiv container
+var px="px" // position suffix with "px" in some cases
+
+function nsfix(){setTimeout("window.onresize = rebrowse", 2000);}
+
+function rebrowse(){window.location.reload();}
+
+function hascss(){ return gettip('infodiv')?true:false }
+
+function infoinit(){
+ ns4=(document.layers)?true:false, ie4=(document.all)?true:false;
+ ie5=((ie4)&&((navigator.userAgent.indexOf('MSIE 5')>0)||(navigator.userAgent.indexOf('MSIE 6')>0)))?true:false;
+ kon=(navigator.userAgent.indexOf('konqueror')>0)?true:false;
+ x=0;y=0;winW=800;winH=600;
+ idiv=null;
+ document.onmousemove = mousemove;
+ if(ns4&&document.captureEvents) document.captureEvents(Event.MOUSEMOVE);
+ // Workaround for just another netscape bug: Fix browser confusion on resize
+ // obviously conqueror has a similar problem :-(
+ if(ns4||kon){ nsfix() }
+ if(ns4) { px=""; }
+}
+
+function untip(){
+ if(idiv) idiv.visibility=ns4?"hide":"hidden";
+ idiv=null;
+}
+
+function gettip(name){return (document.layers&&document.layers[name])?document.layers[name]:(document.all&&document.all[name]&&document.all[name].style)?document.all[name].style:document[name]?document[name]:(document.getElementById(name)?document.getElementById(name).style:0);}
+
+// Prepare tip boxes, but don't show them yet
+function maketip(name,title,text){
+ if(hascss()) document.write('<div id="'+name+'" name="'+name+'" style="position:absolute; visibility:hidden; z-index:20; top:0'+px+'; left:0'+px+';"><table width='+IWIDTH+' border=0 cellpadding=2 cellspacing=0 bgcolor="#333399"><tr><td class="tiptd"><table width="100%" border=0 cellpadding=0 cellspacing=0><tr><th><span class="ptt"><b><font color="#FFFFFF">'+title+'</font></b></span></th></tr></table><table width="100%" border=0 cellpadding=2 cellspacing=0 bgcolor="#CCCCFF"><tr><td><span class="pst"><font color="#000000">'+text+'</font></span></td></tr></table></td></tr></table></div>'+"\n");
+}
+
+function tip(name){
+ if(hascss()){
+ if(idiv) untip();
+ idiv=gettip(name);
+ if(idiv){
+ winW=(window.innerWidth)? window.innerWidth+window.pageXOffset-16:document.body.offsetWidth-20;
+ winH=(window.innerHeight)?window.innerHeight+window.pageYOffset :document.body.offsetHeight;
+ if(x<=0||y<=0){ // konqueror can't get mouse position
+ x=(winW-IWIDTH)/2+(window.pageXOffset?window.pageXOffset:0); y=(winH-50)/2+(window.pageYOffset?window.pageYOffset:0); // middle of window
+ }
+ showtip();
+ }
+ }
+}
+
+function showtip(){
+ idiv.left=(((x+260)<winW)?x+12:x-255)+px; idiv.top=(((y+90)<winH)?y+12:y-90)+px;
+ idiv.visibility=ns4?"show":"visible";
+// window.status="idiv="+idiv+"X:"+(idiv.left?idiv.left:"NAN")+", Y:"+(idiv.top?idiv.top:"NAN")+", x:"+x+", y:"+y;
+}
+
+function mousemove(e){
+ if(e) {x=e.pageX?e.pageX:e.clientX?e.clientX:0; y=e.pageY?e.pageY:e.clientY?e.clientY:0;}
+ else if(event) {x=event.clientX; y=event.clientY;}
+ else {x=0; y=0;}
+ if((ie4||ie5) && document.documentElement) // Workaround for scroll offset of IE
+ {
+ x+=document.documentElement.scrollLeft;
+ y+=document.documentElement.scrollTop;
+ }
+ if(idiv) showtip();
+}
+
+// Initialize after loading the page
+window.onload=infoinit;
+
+// EOF infobox.js
|