-
Bug
-
Resolution: Fixed
-
P2
-
1.4.1
-
b17
-
x86
-
windows_98
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-2056269 | 5.0 | Leif Samuelsson | P2 | Resolved | Fixed | tiger |
Name: jk109818 Date: 07/09/2002
FULL PRODUCT VERSION :
java version "1.4.1-beta"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1-beta-b14)
Java HotSpot(TM) Client VM (build 1.4.1-beta-b14, mixed mode)
FULL OPERATING SYSTEM VERSION :
Windows 98 [Version 4.10.2222]
A DESCRIPTION OF THE PROBLEM :
Using the file chooser, browse to a directory with many files,
the dialog takes a long time to show. After it shows, it
will takes a long time to show the files.
The folder I tested with has:
1545 files and 49 folders. Note that Notepad.exe open this
instantly.
There is a related bug that is closed: 4621272
It says that it fixes the bug in hopper, unfortunately, I
have no way of knowing if j2sdk1.4.1 beta is "hopper" or not.
Also, note that the 2 bugs are different. The related bug
show slowness when select many files.
This bug shows slowness by merely open a directory.
Also note that with j2sdk1.4.1 beta, the previous bug is
still there, and select 1 file, the select another file,
there is a long pause between (inconsistently though, and
only happen in a directory with many files - note: just
select 1 file, not many files).
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1) Run the application
1) Open a JFileChooser
2) Browse to a directory that has many files
(it's even better to have the first directory of
JFileChooser to have many files to show the effect of slowness).
EXPECTED VERSUS ACTUAL BEHAVIOR :
Things work faster.
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
import javax.swing.*;
import java.io.*;
public class BugDemonstration
{
public static void main(String args[])
{
final JFrame frame = new JFrame("The Frame");
frame.setDefaultCloseOperation (JFrame.EXIT_ON_CLOSE);
frame.setSize(200,200);
frame.setVisible(true);
SwingUtilities.invokeLater(new Runnable()
{
public void run()
{
JFileChooser file = new JFileChooser();
file.setMultiSelectionEnabled(true);
file.setDialogTitle
("Select lots of files..." );
file.showDialog(frame.getContentPane(), "Demonstrate problem");
File [] selected = file.getSelectedFiles();
System.out.println (selected.length+" files selected.");
}
});
}
}
---------- END SOURCE ----------
(Review ID: 158588)
======================================================================
- backported by
-
JDK-2056269 JFileChooser is very slow when browsing many files in a directory
- Resolved
- relates to
-
JDK-4679673 JFileChooser.setSelectedFiles() is very slow for multiple select
- Resolved
-
JDK-4858226 REGRESSION: User can not enter "C:\My Documents" directory using JFileChooser
- Closed
-
JDK-5033747 JFileChooser is very slow on Windows XP
- Closed
-
JDK-4889108 Code cleanup: Remove fallback code for "fileChooserSpeedFix"
- Resolved
-
JDK-4711700 NullPointerException in JFileChooser when accessing system level icons
- Resolved
-
JDK-4480327 1.4's JFileChooser extremely slow for remote folders
- Closed