[portal-commits] JBoss Portal SVN: r11983 - branches/JBoss_Portal_Branch_2_6/core/src/resources/portal-core-war/WEB-INF/jsp/content.

portal-commits at lists.jboss.org portal-commits at lists.jboss.org
Thu Sep 25 10:53:22 EDT 2008


Author: wesleyhales
Date: 2008-09-25 10:53:22 -0400 (Thu, 25 Sep 2008)
New Revision: 11983

Modified:
   branches/JBoss_Portal_Branch_2_6/core/src/resources/portal-core-war/WEB-INF/jsp/content/portlet_editor.jsp
Log:
https://jira.jboss.org/jira/browse/JBPORTAL-2175

Modified: branches/JBoss_Portal_Branch_2_6/core/src/resources/portal-core-war/WEB-INF/jsp/content/portlet_editor.jsp
===================================================================
--- branches/JBoss_Portal_Branch_2_6/core/src/resources/portal-core-war/WEB-INF/jsp/content/portlet_editor.jsp	2008-09-25 14:50:14 UTC (rev 11982)
+++ branches/JBoss_Portal_Branch_2_6/core/src/resources/portal-core-war/WEB-INF/jsp/content/portlet_editor.jsp	2008-09-25 14:53:22 UTC (rev 11983)
@@ -109,20 +109,15 @@
 
             String iconLocation = getIcon(info);
             String linkId="portlet-instance-link"+"_"+index;
+            String displayNameId = "info-container-" + displayName.replace("'","/'");
         %>
         <portlet:actionURL var="url">
           <portlet:param name="content.action.select" value="true"/>
           <portlet:param name="content.uri" value="<%= instance.getId() %>"/>
         </portlet:actionURL>
 
-         <script type="text/javascript">
-            //escape single quote and others for js
-            var infoContainerId<%=index%> = "<%= displayName %>".replace(/'/,"/'");
-            infoContainerId<%=index%> = 'info-container-' + infoContainerId<%=index%>;
-         </script>
-
         <div style="display:none">
-          <div class="darktip" id="" name="darktip<%=index%>">
+          <div class="darktip" id="<%=displayNameId%>">
             <div class="toolbar" style="width: 250px;">
               <div class="title"><%= getLocalizedValue(portletMetaInfo.getMetaValue(MetaInfo.TITLE), locale) %>
               </div>
@@ -137,21 +132,16 @@
           </div>
         </div>
 
-
          <script type="text/javascript">
-           //assign dynamically generated id
-            var darktip<%=index%> = document.getElementsByName('darktip<%=index%>')[0];
-            try{
-               darktip<%=index%>.setAttribute("id", infoContainerId<%=index%>);
-            }catch(e){
-                //alert(e);
+            function showToolTip<%=index%>(element,event){
+               return domTT_activate(element, event, "content", document.getElementById("<%=displayNameId%>"),"delay", 0, "trail", false, "fade", "both", "fadeMax", 95, "styleClass", "none");
             }
          </script>
 
         <tr class="<%= rowClass %>">
           <td>
             <img src="<%= iconLocation %>" align="middle" style="margin:0 4px 0 0" alt="icon"/>
-            <span onmouseover="domTT_activate(this, event, 'content', document.getElementById(infoContainerId<%=index%>),'delay', 0, 'trail', false, 'fade', 'both', 'fadeMax', 95, 'styleClass', 'none');"><a
+            <span onmouseover="showToolTip<%=index%>(this,event);"><a
                     href="<%= url %>" id="<%= linkId %>"><%= displayName %>
             </a></span></td>
         </tr>




More information about the portal-commits mailing list