Use JFileChooser.getDescription(File) instead of JFileChooser.getTypeDescription(File) to check file type.