use of javax.swing.plaf.metal.MetalFileChooserUI in project jdk8u_jdk by JetBrains.
the class bug6342301 method main.
public static void main(String[] args) throws Exception {
tempDir = System.getProperty("java.io.tmpdir");
if (tempDir.length() == 0) {
//'java.io.tmpdir' isn't guaranteed to be defined
tempDir = System.getProperty("user.home");
}
System.out.println("Temp directory: " + tempDir);
UIManager.setLookAndFeel(new MetalLookAndFeel());
SwingUtilities.invokeAndWait(new Runnable() {
public void run() {
HackedFileChooser openChooser = new HackedFileChooser();
openChooser.setUI(new MetalFileChooserUI(openChooser));
openChooser.setCurrentDirectory(new File(tempDir));
}
});
}
Aggregations