From 9e881820b85cc28660474202f7bbf61b84605720 Mon Sep 17 00:00:00 2001 From: skeeter Date: Tue, 8 May 2001 18:49:37 +0000 Subject: [PATCH] Changed the font size to be dynamic to the users browser. --- phpgwapi/inc/class.menutree.inc.php | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/phpgwapi/inc/class.menutree.inc.php b/phpgwapi/inc/class.menutree.inc.php index a820e19aee..678e1a1ce2 100644 --- a/phpgwapi/inc/class.menutree.inc.php +++ b/phpgwapi/inc/class.menutree.inc.php @@ -247,7 +247,23 @@ var $last_column_size; $maxlevel++; - $cnt=0; +// $cnt=0; + + $browser = CreateObject('phpgwapi.browser'); + $browser->browser(); + $browser_agent = $browser->get_agent(); + switch($browser_agent) + { + case 'MOZILLA': + case 'NETSCAPE': + $text_size = 3; + break; + case 'IE': + $text_size = 2; + break; + } + + for($cnt=0;$cnt<$c_tree - 1;$cnt++) { if(!$visible[$cnt]) @@ -365,7 +381,7 @@ var $last_column_size; /****************************************/ /* output item text */ /****************************************/ - $str .= ''; + $str .= ''; if ($tree[$cnt][5]=='') { if ($tree[$cnt][2]=='')