bug-classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug classpath/25192] New: updateChildren in javax.swing.text.View.java


From: langel at redhat dot com
Subject: [Bug classpath/25192] New: updateChildren in javax.swing.text.View.java is inefficent
Date: 30 Nov 2005 22:33:03 -0000

This function is very inefficent. If added.length is something like 800, it
takes an extremely long time to finish- or it doesn't finish at all.

There must be a better way to implement this. Maybe someone who knows more
about this class can take a look.

Thanks

  protected boolean updateChildren(DocumentEvent.ElementChange ec,
                                   DocumentEvent ev,
                                   ViewFactory vf)
  {
    Element[] added = ec.getChildrenAdded();

    ....

    View[] newChildren = new View[added.length]; 
    for (int i = 0; i < added.length; ++i) 
      newChildren[i] = vf.create(added[i]); 

    ...
  }


-- 
           Summary: updateChildren in javax.swing.text.View.java is
                    inefficent
           Product: classpath
           Version: 0.19
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: classpath
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: langel at redhat dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25192





reply via email to

[Prev in Thread] Current Thread [Next in Thread]