diff options
Diffstat (limited to 'platform/java/example/Viewer.java')
-rw-r--r-- | platform/java/example/Viewer.java | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/platform/java/example/Viewer.java b/platform/java/example/Viewer.java index e5c45be4..a559c218 100644 --- a/platform/java/example/Viewer.java +++ b/platform/java/example/Viewer.java @@ -431,15 +431,7 @@ public class Viewer extends Frame implements WindowListener, ActionListener, Ite fileDialog.setDirectory(System.getProperty("user.dir")); fileDialog.setFilenameFilter(new FilenameFilter() { public boolean accept(File dir, String name) { - if (name.endsWith(".pdf")) return true; - if (name.endsWith(".xps")) return true; - if (name.endsWith(".oxps")) return true; - if (name.endsWith(".cbt")) return true; - if (name.endsWith(".cbz")) return true; - if (name.endsWith(".epub")) return true; - if (name.endsWith(".fb2")) return true; - if (name.endsWith(".xhtml")) return true; - return false; + return Document.recognize(name); } }); fileDialog.setVisible(true); |