commit 0852836d45a0a6f894b061cd3b8821e6f3d5c737
parent d1399f54f786f2a79438859e7792ab234efb1f9e
Author: dankert <devnull@localhost>
Date: Thu, 3 May 2007 23:18:14 +0200
Nicht aktive Men?punkte als inaktiv anzeigen.
Diffstat:
2 files changed, 19 insertions(+), 6 deletions(-)
diff --git a/actionClasses/Action.class.php b/actionClasses/Action.class.php
@@ -20,6 +20,9 @@
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
// ---------------------------------------------------------------------------
// $Log$
+// Revision 1.31 2007-05-03 21:18:14 dankert
+// Nicht aktive Men?punkte als inaktiv anzeigen.
+//
// Revision 1.30 2007-04-21 11:49:40 dankert
// Keine Variable "style" verwenden (?berschreibt andere Variablen!)
//
@@ -527,12 +530,15 @@ class Action
$menuKey = 'accesskey_window_'.$menuName;
// Logger::trace("testing menu $menuName");
+ $menuEntry = array('subaction'=>$menuName,
+ 'text' =>$menuText,
+ 'title' =>$menuText.'_DESC',
+ 'key' =>$menuKey );
+
if ( $this->checkMenu($menuName) )
- $windowMenu[] = array('subaction'=>$menuName,
- 'text' =>$menuText,
- 'title' =>$menuText.'_DESC',
- 'key' =>$menuKey,
- 'url'=>Html::url($actionName,$menuName,$this->getRequestId()) );
+ $menuEntry['url'] = Html::url($actionName,$menuName,$this->getRequestId());
+
+ $windowMenu[] = $menuEntry;
}
$this->setTemplateVar('windowMenu',$windowMenu);
}
diff --git a/themes/default/include/html/window.inc.php b/themes/default/include/html/window.inc.php
@@ -52,7 +52,14 @@
if ( $tmp_pos !== false )
$tmp_text = substr($tmp_text,0,max($tmp_pos,0)).'<span class="accesskey">'. substr($tmp_text,$tmp_pos,1).'</span>'.substr($tmp_text,$tmp_pos+1);
- ?><a href="<?php echo Html::url($actionName,$menu['subaction'],$this->getRequestId() ) ?>" accesskey="<?php echo $tmp_key ?>" title="<?php echo lang($menu['text'].'_DESC') ?>" class="menu<?php echo $this->subActionName==$menu['subaction']?'_highlight':'' ?>"><?php echo $tmp_text ?></a> <?php
+ if ( isset($menu['url']) )
+ {
+ ?><a href="<?php echo Html::url($actionName,$menu['subaction'],$this->getRequestId() ) ?>" accesskey="<?php echo $tmp_key ?>" title="<?php echo lang($menu['text'].'_DESC') ?>" class="menu<?php echo $this->subActionName==$menu['subaction']?'_highlight':'' ?>"><?php echo $tmp_text ?></a> <?php
+ }
+ else
+ {
+ ?><span class="menu_disabled" title="<?php echo lang($menu['text'].'_DESC') ?>" class="menu_disabled"><?php echo $tmp_text ?></span> <?php
+ }
}
if ($conf['help']['enabled'] )
{