Here's one way to hack it:

1) Copy the following to WEB-INF/include/jscookmenu
org.apache.myfaces.custom.navmenu.jscookmenu.resource - JSCookMenu.js,
MyFacesHack.js
org.apache.myfaces.custom.navmenu.jscookmenu.resource.ThemeOffice -
theme.css, theme.js

2) Add the following to the copied theme.css
.ThemeOfficeMenuItemTextDisabled
{
  padding-top:  2px;
  padding-bottom: 2px;
  padding-left: 5px;
  padding-right:  5px;
  border-top: 1px solid #3169C6;
  border-bottom:  1px solid #3169C6;
  background-color: inherit;
  white-space:  nowrap;
}

3) Insert into JSCookMenu,js, function cmDrawSubMenu (starts at line 190 in
the version I have)
         if (item[0] != null)
               str += item[0];
         else
               str += hasChild ? nodeProperties.folderLeft :
nodeProperties.itemLeft;

i>       // 2005/11/01 caw add style to non-clickable items to make them
appear disabled (gray out) 
i>       if (item[2] != null)  // item[2] is the link url
               str += '<td class="' + classStr + 'Text">' + item[1];
i>       else
i>             str += '<td class="' + classStr + 'TextDisabled">' + item[1];

         str += '<td class="' + classStr + 'Right">';

4) The jscookMenu tag
<x:jscookMenu layout="hbr" 
        theme="ThemeOffice" 
        styleLocation="include/jscookmenu"
        javascriptLocation="include/jscookmenu">

HTH,
Dan

On 2/2/06, Thomas Spiegl <[EMAIL PROTECTED]> wrote:
> 
> hi tony,
> 
> JSCookMenu does not support this feature, but it would be a 
> nice enhancement.
> If you could implement it and send us a patch, this woudl be greait!
> 
> cheers
> Thomas
> 
> On 2/2/06, tony kerz <[EMAIL PROTECTED]> wrote:
> > anyone aware of a way to grey out a jscook menu item dynamically?


Disclaimer: This e-mail message is intended only for the personal use of 
the recipient(s) named above.  If you are not an intended recipient, you 
may not review, copy or distribute this message. If you have received this
communication in error, please notify us immediately by e-mail and delete 
the original message.
This e-mail expresses views only of the sender, which are not to be 
attributed to Rite Aid Corporation and may not be copied or distributed 
without this statement.

Reply via email to