[richfaces-issues] [JBoss JIRA] Created: (RF-3670) Modal Panel preventFocus JS function slow

Tom Tamulewicz (JIRA) jira-events at lists.jboss.org
Tue Jun 10 09:28:15 EDT 2008


Modal Panel preventFocus JS function slow
-----------------------------------------

                 Key: RF-3670
                 URL: http://jira.jboss.com/jira/browse/RF-3670
             Project: RichFaces
          Issue Type: Bug
    Affects Versions: 3.1.5
         Environment: Windows XP, Sun RI 1.2
            Reporter: Tom Tamulewicz


I have a page with a 500 row table.  Each row has a "delete" link that brings up a modal panel.  The modal panel takes 4-5 seconds (with CPU spiked) to appear under MSIE 6 or 7.  The time it takes to show up is proportional to how many rows in the table.  If I have a small number, the modal panel shows quickly.  The problem appears to be due to slowness in the modalPanel.js preventFocus() function, which is called from the show() function.  

My test page wasn't very complicated, with a bean providing a list of 500 objects.  

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns:ui="http://java.sun.com/jsf/facelets"
  xmlns:h="http://java.sun.com/jsf/html"
  xmlns:f="http://java.sun.com/jsf/core"
  xmlns:rich="http://richfaces.org/rich"
  xmlns:a4j="http://richfaces.org/a4j"    
<body>
<!-- The text above will not be rendered. -->
<ui:composition>

  <h:form id="testForm">

       <rich:modalPanel id="confirmModal" height="200" width="425"  zindex="2000" resizeable="false">

        <table width="100%">
          <tr>
            <td align="center" colspan="3">
              <h:commandButton id="yes" value="yes"/>
	        </td>
            <td align="center" colspan="3">
              <h:commandButton id="no" value="no"/>
	        </td>
          </tr>
        </table>
      </rich:modalPanel>


    <rich:dataTable id="testTable" value="#{testList.dataList}" var="element">
      <rich:column>
        <h:outputText value='#{element.index}' />
	  </rich:column>	   
      <rich:column>
        <h:outputText value='#{element.name}' />
	  </rich:column>	   
      <rich:column id="deleteObjectColumn" width="10%" sortable="false">
         <a4j:commandLink value="delete" id="commandDialogLink"
            	onclick="Richfaces.showModalPanel('confirmModal',{width:425, top:200});"/>
      </rich:column>
    </rich:dataTable>
  </h:form>
</ui:composition>
<!-- The text below will not be rendered. -->
</body>
</html>

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the richfaces-issues mailing list