updated for changing the hover images

This commit is contained in:
seek3r 2001-12-30 04:58:39 +00:00
parent c2cd9e60d0
commit abf54b9909
2 changed files with 11 additions and 25 deletions

View File

@ -816,15 +816,15 @@
if(isset($this->found_files[$appname]['images'][$image.'.png'])) if(isset($this->found_files[$appname]['images'][$image.'.png']))
{ {
$imgfile = $GLOBALS['phpgw_info']['server']['webserver_url'].$this->found_files[$appname]['images'][$image.'.png'].'/'.$image; $imgfile = $GLOBALS['phpgw_info']['server']['webserver_url'].$this->found_files[$appname]['images'][$image.'.png'].'/'.$image.'.png';
} }
elseif(isset($this->found_files[$appname]['images'][$image.'.jpg'])) elseif(isset($this->found_files[$appname]['images'][$image.'.jpg']))
{ {
$imgfile = $GLOBALS['phpgw_info']['server']['webserver_url'].$this->found_files[$appname]['images'][$image.'.jpg'].'/'.$image; $imgfile = $GLOBALS['phpgw_info']['server']['webserver_url'].$this->found_files[$appname]['images'][$image.'.jpg'].'/'.$image.'.jpg';
} }
elseif(isset($this->found_files[$appname]['images'][$image.'.gif'])) elseif(isset($this->found_files[$appname]['images'][$image.'.gif']))
{ {
$imgfile = $GLOBALS['phpgw_info']['server']['webserver_url'].$this->found_files[$appname]['images'][$image.'.gif'].'/'.$image; $imgfile = $GLOBALS['phpgw_info']['server']['webserver_url'].$this->found_files[$appname]['images'][$image.'.gif'].'/'.$image.'.gif';
} }
elseif(isset($this->found_files[$appname]['images'][$image])) elseif(isset($this->found_files[$appname]['images'][$image]))
{ {
@ -845,30 +845,16 @@
$image_found = $this->find_image($appname,$image[$i]); $image_found = $this->find_image($appname,$image[$i]);
$c_image = count($image); $c_image = count($image);
while($image_found == '' && $i<$c_image) while($image_found == '' && $i<$c_image)
{
if($this->found_files[$appname]['images'][$image[$i]])
{
$image_found = $GLOBALS['phpgw_info']['server']['webserver_url'].$this->found_files[$appname]['images'][$image[$i]].'/'.$image[$i];
}
else
{ {
$image_found = $this->find_image($appname,$image[$i]); $image_found = $this->find_image($appname,$image[$i]);
}
$i++; $i++;
} }
return $image_found; return $image_found;
} }
elseif($image != '') elseif($image != '')
{
if($this->found_files[$appname]['images'][$image])
{
return $GLOBALS['phpgw_info']['server']['webserver_url'].$this->found_files[$appname]['images'][$image].'/'.$image;
}
else
{ {
return $this->find_image($appname,$image); return $this->find_image($appname,$image);
} }
}
else else
{ {
return ''; return '';
@ -917,17 +903,17 @@
$GLOBALS['phpgw_info']['navbar'][$permission[0]]['title'] = $GLOBALS['phpgw_info']['apps'][$permission[0]]['title']; $GLOBALS['phpgw_info']['navbar'][$permission[0]]['title'] = $GLOBALS['phpgw_info']['apps'][$permission[0]]['title'];
$GLOBALS['phpgw_info']['navbar'][$permission[0]]['url'] = $GLOBALS['phpgw']->link('/' . $permission[0] . '/index.php'); $GLOBALS['phpgw_info']['navbar'][$permission[0]]['url'] = $GLOBALS['phpgw']->link('/' . $permission[0] . '/index.php');
$GLOBALS['phpgw_info']['navbar'][$permission[0]]['name'] = $permission[0]; $GLOBALS['phpgw_info']['navbar'][$permission[0]]['name'] = $permission[0];
/*
if ($permission[0] != $GLOBALS['phpgw_info']['flags']['currentapp']) if ($permission[0] != $GLOBALS['phpgw_info']['flags']['currentapp'])
{ {
$GLOBALS['phpgw_info']['navbar'][$permission[0]]['icon'] = $this->image($permission[0],'navbar'); $GLOBALS['phpgw_info']['navbar'][$permission[0]]['icon'] = $this->image($permission[0],'navbar');
$GLOBALS['phpgw_info']['navbar'][$permission[0]]['icon_hover'] = $this->image_on($permission[0],'navbar','-over');
} }
else else
{ {
$GLOBALS['phpgw_info']['navbar'][$permission[0]]['icon'] = $this->image_on($permission[0],'navbar','-over'); $GLOBALS['phpgw_info']['navbar'][$permission[0]]['icon'] = $this->image_on($permission[0],'navbar','-over');
$GLOBALS['phpgw_info']['navbar'][$permission[0]]['icon_hover'] = $this->image($permission[0],'navbar');
} }
*/
$GLOBALS['phpgw_info']['navbar'][$permission[0]]['icon'] = $this->image($permission[0],'navbar.gif');
if($GLOBALS['phpgw_info']['navbar'][$permission[0]]['icon'] == '') if($GLOBALS['phpgw_info']['navbar'][$permission[0]]['icon'] == '')
{ {
@ -1785,3 +1771,4 @@
} }
} }
}//end common class }//end common class

View File

@ -56,9 +56,8 @@
{ {
$title = '<img src="' . $app[1]['icon'] . '" alt="' . $app[1]['title'] . '" title="' $title = '<img src="' . $app[1]['icon'] . '" alt="' . $app[1]['title'] . '" title="'
. lang($app[1]['title']) . '" border="0" name="' . $app[0] . '">'; . lang($app[1]['title']) . '" border="0" name="' . $app[0] . '">';
$img_src_over = $app[1]['icon_hover'];
$img_src_over = $GLOBALS['phpgw']->common->image($app[0],'navbar-over.gif'); $img_src_out = $app[1]['icon'];
$img_src_out = $GLOBALS['phpgw']->common->image($app[0],'navbar.gif');
// onMouseOver="two.src='rollover/admin_over.gif'" onMouseOut="two.src='images/admin.gif'"><img src="images/admin.gif" border="0" name="two" // onMouseOver="two.src='rollover/admin_over.gif'" onMouseOut="two.src='images/admin.gif'"><img src="images/admin.gif" border="0" name="two"
$applications .= '<tr><td><a href="' . $app[1]['url'] . '"'; $applications .= '<tr><td><a href="' . $app[1]['url'] . '"';