USEPA / emf

Emissions Modeling Framework (EMF)
6 stars 3 forks source link

folders can't be opened via keyboard in local file browser #65

Closed cseppan closed 3 years ago

cseppan commented 3 years ago

Steps to reproduce:

File > Import Click the Browse button, then select the Local tab Single click on a folder Hitting Enter doesn't open the selected folder

Here's a quick program that shows a basic JFileChooser. When a folder is selected, the Upload button changes to Open. Hitting Enter activates that button.

public class TestApp {
    public static void main(String args[]) {
        JFrame window = new JFrame("Test App");
        window.setSize(600, 500);

        JFileChooser fc = new JFileChooser();
        fc.setApproveButtonText("Upload");
        window.add(fc);
        window.setVisible(true);
   }
}

In EmfFileChooser.java, the standard control buttons aren't shown. Instead a separate Upload button triggers the file upload.