You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Leonardo Uribe (JIRA)" <de...@myfaces.apache.org> on 2008/10/01 00:59:44 UTC
[jira] Resolved: (TOMAHAWK-1337) swapImage renders onmouseover and
onmouseout twice
[ https://issues.apache.org/jira/browse/TOMAHAWK-1337?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Leonardo Uribe resolved TOMAHAWK-1337.
--------------------------------------
Resolution: Fixed
Fix Version/s: 1.1.8-SNAPSHOT
Assignee: Leonardo Uribe
thanks to Paul Rivera for provide us this patch
> swapImage renders onmouseover and onmouseout twice
> --------------------------------------------------
>
> Key: TOMAHAWK-1337
> URL: https://issues.apache.org/jira/browse/TOMAHAWK-1337
> Project: MyFaces Tomahawk
> Issue Type: Bug
> Affects Versions: 1.1.8-SNAPSHOT
> Environment: tomcat 6.0.16
> java 1.6.0
> tomahawk 1.1.8-SNAPSHOT
> Reporter: Paul Rivera
> Assignee: Leonardo Uribe
> Priority: Minor
> Fix For: 1.1.8-SNAPSHOT
>
> Attachments: HtmlSwapImageRenderer.patch, shared-2.0.9-SNAPSHOT.patch, shared-3.0.5-SNAPSHOT.patch
>
>
> Here's what my page rendered for my swapImage:
> <img id="_idJsp0:foo" src="/MYFACES11-Playground/images/MyFaces_logo.jpg" onmouseover="SI_MM_swapImage('_idJsp0:foo','','/MYFACES11-Playground/images/feather.gif',1);" onmouseout="SI_MM_swapImgRestore();" border="Integer.MIN_VALUE" onmouseover="alert('onmouseover2');" onmouseout="alert('onmouseout2');" />
> As you can see, onmouseover and onmouseout are rendered twice. In this case, alert('onmouseover2') and alert('onmouseout2') never get executed.
> Both onmouseover and onmouseout attributes are not declared as attributes of swapImage tag in tomahawk.tld. You can only replicate this bug if you bind your swapImage object to a bean. Here's my bean:
> public class SwapImageBean
> {
> private HtmlSwapImage swapImage;
>
> public SwapImageBean() {
> swapImage = new HtmlSwapImage();
> swapImage.getAttributes().put(HTML.ONMOUSEOVER_ATTR, "alert('onmouseover2');");
> swapImage.getAttributes().put(HTML.ONMOUSEOUT_ATTR, "alert('onmouseout2');");
> }
> public HtmlSwapImage getSwapImage()
> {
> return swapImage;
> }
> public void setSwapImage(HtmlSwapImage swapImage)
> {
> this.swapImage = swapImage;
> }
> }
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.