myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sol Kindle (JIRA)" <...@myfaces.apache.org>
Subject [jira] Issue Comment Edited: (TOMAHAWK-83) Changes in navigationMenuItem jsf component to make it work with HtmlCommandJSCookMenu (action) or any simple URL
Date Tue, 21 Aug 2007 17:29:31 GMT

    [ https://issues.apache.org/jira/browse/TOMAHAWK-83?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12520392
] 

kindsol edited comment on TOMAHAWK-83 at 8/21/07 10:27 AM:
--------------------------------------------------------------

Attached patches are out of date with head.  I implemented the tomahawk-83_r566869.patch based
on the changes made in the old patches.  This new patch simply adds a "url" attribute to the
<t:navigationMenuItem> tag.  This tag will allow simple (hard-coded) text urls or EL
values containing urls.  

This patch is very important because EL values containing urls are not currently accepted,
for example:

<t:navigationMenuItem itemLabel="gotoFoo" action="http://www.foo.com"  /> works just
fine, but
<t:navigationMenuItem itemLabel="gotoFoo" action="#{msg.fooUrlString}"  /> doesn't --
it is interpreted as an action method.

Users who need to localize/internationalize their jscook menu component, cannot currently
do so.  With the new "url" tag attribute as provided by this patch, the action tag in no longer
overloaded -- any expression or value in the url attribute is evaluated as a url, for example
with this patch:

<t:navigationMenuItem itemLabel="gotoFoo" url="http://www.foo.com"  /> works, and also
<t:navigationMenuItem itemLabel="gotoFoo" url="#{msg.fooUrlString}"  /> works!

This change is necessary for users who need to localize/internationalize their jscook menu
component.

Please let me know if you have any questions.

      was (Author: kindsol):
    Attached patches are out of date with head.  I implemented the tomahawk-83_r566869.patch
based on the changes made in the old patches.  This new patch simply adds a "url" attribute
to the <t:navigationMenuItem> tag.  This will allow simple (hard-coded) text urls or
EL values containing urls.  

This patch is very important because is will allow EL values containing urls which allows
users to localize/internationalize their jscook menu component.

Please let me know if you have any questions.
  
> Changes in navigationMenuItem jsf component to make it work with HtmlCommandJSCookMenu
(action) or any simple URL
> -----------------------------------------------------------------------------------------------------------------
>
>                 Key: TOMAHAWK-83
>                 URL: https://issues.apache.org/jira/browse/TOMAHAWK-83
>             Project: MyFaces Tomahawk
>          Issue Type: Bug
>          Components: JS Cook Menu, NavigationMenuItem
>         Environment: JDK 1.5.0_03-b07, JBoss 4.0.2, Windows XP SP2
>            Reporter: Darlan Oliveira
>            Assignee: Thomas Spiegl
>         Attachments: myfaces-1.0.9.zip, patch.1.1.1.zip, tomahawk-83_r566869.patch
>
>
> 1) src/components/org/apache/myfaces/custom/navmenu/HtmlNavigationMenuItemTag.java
> Inserted constants.: URL_ATTR and TARGET_ATTR
> Inserted attributes: _url and _target
> Inserted methods...: setUrl and setTarget
> Modified methods...: release and setProperties
> 2) src/components/org/apache/myfaces/custom/navmenu/NavigationMenuItem.java
> Inserted attributes..: _url and _target
> Inserted constructors: NavigationMenuItem(Object, String, String, boolean, boolean, String,
String, String, String, boolean)
>                        NavigationMenuItem(String, String, String, String, boolean)
> Modified constructors: NavigationMenuItem(Object, String, String, boolean, String, String,
boolean)
>                        NavigationMenuItem(String, String, String, boolean)
> Inserted methods.....: get/setUrl and get/setTarget
> 3) src/components/org/apache/myfaces/custom/navmenu/NavigationMenuUtils.java
> Modified method: getNavigationMenuItemList
> 4) src/components/org/apache/myfaces/custom/navmenu/UINavigationMenuItem.java
> Inserted attributes: _url and _target
> Inserted methods...: get/setUrl and get/setTarget
> Modified methods...: restoreState and saveState
> 5) src/components/org/apache/myfaces/custom/navmenu/jscookmenu/HtmlJSCookMenuRenderer.java
> Modified method: encodeNavigationMenuItems
> 6) src/components/org/apache/myfaces/custom/navmenu/resource/jscookmenu/JSCookMenu.js
> Modified function: cmItemMouseUp
> 7) tlds/myfaces_ext.tld
> Inserted attributes: url and target
> 8) tlds/myfaces_ext_sf.tld
> Inserted attributes: url and target

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message