Code

Fixed create missing trees
[gosa.git] / include / class_divlist.inc
index 17176b217b9ce96ffbe8d5f2b743a2a0ecc61291..9c52b768c9044d714fc81ea9eef9820b53d6f744 100644 (file)
@@ -18,6 +18,7 @@ class divlist {
 
   var $force_height = false;
   var $list_footer = "";
+  var $fix_list_for_plugins = FALSE;
   
        // Added php 4 constructor
        function divlist($pageid){
@@ -38,6 +39,11 @@ class divlist {
        
        }
 
+  function SetPluginMode($val = TRUE)
+  {
+    $this->fix_list_for_plugins = $val;
+  }
+
   function SetFooter($str)
   {
     $this->list_footer = $str;
@@ -184,7 +190,7 @@ class divlist {
    
     if($this->i_entriesPerPage == 0) {
       // We need to construct a "body"-table that is width-of-scrollbar thinner than the "head"-table.
-      if(!$this->force_height) {
+      if(!$this->force_height || $this->fix_list_for_plugins) {
         $s_return .= "\n<tr><td colspan='".$this->cols."' class='scrollbody'><div style='width:".$this->s_width.";height:".($this->s_height-20)."px;' id='d_scrollbody' class='scrollbody'>";
         $s_return .= "<table summary='' style='height:100%;width:581px;' cellspacing='0' id='t_scrollbody'>";
       } else {
@@ -235,7 +241,7 @@ class divlist {
                    // Alternation of background color          
                                if($i_alternate) $i_alternate=0; else $i_alternate=1;
                                
-                               $s_return .= "\n<tr>";
+          $s_return .= "\n<tr class='rowxp".$i_alternate."'>";
                                
                                $cnt = 0;