tapestry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jkuhn...@apache.org
Subject svn commit: r481812 - in /tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry: html/Rollover.script link/DefaultLinkRenderer.java
Date Sun, 03 Dec 2006 17:03:55 GMT
Author: jkuhnert
Date: Sun Dec  3 09:03:49 2006
New Revision: 481812

URL: http://svn.apache.org/viewvc?view=rev&rev=481812
Log:
Fixes TAPESTRY-1159. Rollover component had a <unique> block in the javascript file
that prevented it from properly 
connecting mouseovers to each individual link it was connected to. 

Modified:
    tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/html/Rollover.script
    tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/link/DefaultLinkRenderer.java

Modified: tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/html/Rollover.script
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/html/Rollover.script?view=diff&rev=481812&r1=481811&r2=481812
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/html/Rollover.script
(original)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/html/Rollover.script
Sun Dec  3 09:03:49 2006
@@ -48,7 +48,7 @@
 </let>
 
 <let key="attribute">
-  document.getElementById('${imageId}').src
+  dojo.byId('${imageId}').src
 </let>
 <body>
 tapestry.${onMouseOverName}=function(){
@@ -64,9 +64,7 @@
 }
 </body>
 <initialization>
-<unique>
 dojo.event.connect(dojo.byId("${link.clientId}"), "onmouseover", tapestry, "${onMouseOverName}");
 dojo.event.connect(dojo.byId("${link.clientId}"), "onmouseout", tapestry, "${onMouseOutName}");
-</unique>
 </initialization>
 </script>

Modified: tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/link/DefaultLinkRenderer.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/link/DefaultLinkRenderer.java?view=diff&rev=481812&r1=481811&r2=481812
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/link/DefaultLinkRenderer.java
(original)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/link/DefaultLinkRenderer.java
Sun Dec  3 09:03:49 2006
@@ -47,17 +47,15 @@
 
     public static final ILinkRenderer SHARED_INSTANCE = new DefaultLinkRenderer();
 
-    public void renderLink(IMarkupWriter writer, IRequestCycle cycle,
-            ILinkComponent linkComponent)
+    public void renderLink(IMarkupWriter writer, IRequestCycle cycle, ILinkComponent linkComponent)
     {
         IMarkupWriter wrappedWriter = null;
-
+        
         if (cycle.getAttribute(Tapestry.LINK_COMPONENT_ATTRIBUTE_NAME) != null)
             throw new ApplicationRuntimeException(LinkMessages.noNesting(),
                     linkComponent, null, null);
-
-        cycle.setAttribute(Tapestry.LINK_COMPONENT_ATTRIBUTE_NAME,
-                linkComponent);
+        
+        cycle.setAttribute(Tapestry.LINK_COMPONENT_ATTRIBUTE_NAME, linkComponent);
         
         boolean hasBody = getHasBody();
 



Mime
View raw message