From 12620943a49337bdfb6a5c7296c81c9cd2029067 Mon Sep 17 00:00:00 2001 From: janw Date: Mon, 3 Apr 2006 15:10:53 +0000 Subject: [PATCH] Line Highlighting in divlists git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2957 594d385d-05f5-0310-b6e9-bd551577e9d8 --- html/include/focus.js | 66 ++++++++++++++++++++++++----------- html/themes/default/style.css | 8 +++++ include/class_divlist.inc | 8 ++--- 3 files changed, 58 insertions(+), 24 deletions(-) diff --git a/html/include/focus.js b/html/include/focus.js index 457e67e1c..e8c92c96f 100644 --- a/html/include/focus.js +++ b/html/include/focus.js @@ -217,30 +217,56 @@ function adjust_height(e) { function adjust_width(e) { if (!e) e=window.event; - // Resize the div - var div_width=parseInt(document.defaultView.getComputedStyle(document.getElementById("t_scrolltable"),"").getPropertyValue('width')); - var width= parseInt(window.innerWidth); + // Known to not work with IE + if(document.defaultView) { + // Resize the div + var div_width=parseInt(document.defaultView.getComputedStyle(document.getElementById("t_scrolltable"),"").getPropertyValue('width')); + var width= parseInt(window.innerWidth); - // Resize the body cells + // Resize the body cells var diff= width-div_width-470; - - // window has been upscaled - if(div_width+diff>=600) { - document.getElementById('d_scrollbody').style.width=div_width+diff+"px"; - document.getElementById('t_scrollbody').style.width=(div_width-19)+diff+"px"; + + // window has been upscaled + if(div_width+diff>=600) { + document.getElementById('d_scrollbody').style.width=div_width+diff+"px"; + document.getElementById('t_scrollbody').style.width=(div_width-19)+diff+"px"; - // Resize the Header cells (only the relative-width ones) - document.getElementById('t_scrollhead').style.width=div_width+diff+"px"; - - // window has been downscaled, we must reset the div to 600px - } else if (width < 930) { - // Reset layout (set width to 600px) - div_width=600; - document.getElementById('d_scrollbody').style.width=div_width+"px"; - document.getElementById('t_scrollbody').style.width=(div_width-19)+"px"; + // Resize the Header cells (only the relative-width ones) + document.getElementById('t_scrollhead').style.width=div_width+diff+"px"; + + // window has been downscaled, we must reset the div to 600px + } else if (width < 930) { + // Reset layout (set width to 600px) + div_width=600; + document.getElementById('d_scrollbody').style.width=div_width+"px"; + document.getElementById('t_scrollbody').style.width=(div_width-19)+"px"; - // Resize the Header cells (only the relative-width ones) - document.getElementById('t_scrollhead').style.width=div_width+"px"; + // Resize the Header cells (only the relative-width ones) + document.getElementById('t_scrollhead').style.width=div_width+"px"; + } + } else { + // IE + + } +} + +function highlight(e) { + if(e) { + for(i=0;i"; + $s_return .= "\n"; $s_return .= $s_value2['string']; $s_return .= ""; } @@ -275,9 +275,9 @@ class divlist { $fill= ""; for ($i= 1; $i <= $this->cols; $i++){ if ($i == $this->cols){ - $fill.= " "; + $fill.= " "; } else { - $fill.= " "; + $fill.= " "; } } $s_return.="\n$fill"; -- 2.30.2