diff options
| -rw-r--r-- | firmal/.classpath | 13 | ||||
| -rw-r--r-- | firmal/.settings/org.eclipse.jdt.core.prefs | 6 | ||||
| -rw-r--r-- | firmal/pom.xml | 8 | ||||
| -rw-r--r-- | firmal/src/main/java/bjc/firmal/DirectoryExpected.java | 18 | ||||
| -rw-r--r-- | firmal/src/main/java/bjc/firmal/FirmalBrowserPanel.java | 33 | ||||
| -rw-r--r-- | firmal/src/main/java/module-info.java | 13 |
6 files changed, 43 insertions, 48 deletions
diff --git a/firmal/.classpath b/firmal/.classpath index 002ad57..5e577b9 100644 --- a/firmal/.classpath +++ b/firmal/.classpath @@ -6,11 +6,6 @@ <attribute name="maven.pomderived" value="true"/> </attributes> </classpathentry> - <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"> - <attributes> - <attribute name="maven.pomderived" value="true"/> - </attributes> - </classpathentry> <classpathentry kind="src" output="target/test-classes" path="src/test/java"> <attributes> <attribute name="optional" value="true"/> @@ -18,13 +13,7 @@ <attribute name="test" value="true"/> </attributes> </classpathentry> - <classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources"> - <attributes> - <attribute name="maven.pomderived" value="true"/> - <attribute name="test" value="true"/> - </attributes> - </classpathentry> - <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"> + <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-17"> <attributes> <attribute name="maven.pomderived" value="true"/> </attributes> diff --git a/firmal/.settings/org.eclipse.jdt.core.prefs b/firmal/.settings/org.eclipse.jdt.core.prefs index db24ee7..62544f6 100644 --- a/firmal/.settings/org.eclipse.jdt.core.prefs +++ b/firmal/.settings/org.eclipse.jdt.core.prefs @@ -1,8 +1,8 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=17 org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve -org.eclipse.jdt.core.compiler.compliance=1.8 +org.eclipse.jdt.core.compiler.compliance=17 org.eclipse.jdt.core.compiler.debug.lineNumber=generate org.eclipse.jdt.core.compiler.debug.localVariable=generate org.eclipse.jdt.core.compiler.debug.sourceFile=generate @@ -12,4 +12,4 @@ org.eclipse.jdt.core.compiler.problem.enumIdentifier=error org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore org.eclipse.jdt.core.compiler.release=disabled -org.eclipse.jdt.core.compiler.source=1.8 +org.eclipse.jdt.core.compiler.source=17 diff --git a/firmal/pom.xml b/firmal/pom.xml index 7e460e8..1b2aae5 100644 --- a/firmal/pom.xml +++ b/firmal/pom.xml @@ -4,14 +4,14 @@ <modelVersion>4.0.0</modelVersion> <groupId>bjc</groupId> <artifactId>firmal</artifactId> - <version>0.0.1-SNAPSHOT</version> + <version>0.0.2-SNAPSHOT</version> <name>firmal</name> <description>Local browser for directories of HTML files. Created originally for browsing downloaded tumblr blogs</description> <dependencies> <dependency> <groupId>bjc</groupId> <artifactId>BJC-Utils2</artifactId> - <version>1.0.0</version> + <version>2.0-SNAPSHOT</version> </dependency> </dependencies> <build> @@ -20,8 +20,8 @@ <artifactId>maven-compiler-plugin</artifactId> <version>3.8.0</version> <configuration> - <source>1.8</source> - <target>1.8</target> + <source>1.17</source> + <target>1.17</target> </configuration> </plugin> </plugins> diff --git a/firmal/src/main/java/bjc/firmal/DirectoryExpected.java b/firmal/src/main/java/bjc/firmal/DirectoryExpected.java new file mode 100644 index 0000000..ebd6da9 --- /dev/null +++ b/firmal/src/main/java/bjc/firmal/DirectoryExpected.java @@ -0,0 +1,18 @@ +package bjc.firmal; + +/** + * Exception thrown when we got a directory when should've gotten a non directory. + * @author Ben Culkin + * + */ +public class DirectoryExpected extends RuntimeException { + private static final long serialVersionUID = 6614868098505684922L; + + /** + * Create a new exception. + * @param pth The path to the directory. + */ + public DirectoryExpected(String pth) { + super(String.format("Non-directory '%s' passed where a directory was expected", pth)); + } +}
\ No newline at end of file diff --git a/firmal/src/main/java/bjc/firmal/FirmalBrowserPanel.java b/firmal/src/main/java/bjc/firmal/FirmalBrowserPanel.java index 4eef8e6..3120a2d 100644 --- a/firmal/src/main/java/bjc/firmal/FirmalBrowserPanel.java +++ b/firmal/src/main/java/bjc/firmal/FirmalBrowserPanel.java @@ -24,23 +24,6 @@ import bjc.utils.gui.layout.VLayout; * */ public class FirmalBrowserPanel extends JPanel { - /** - * Exception thrown when we got a directory when should've gotten a non directory. - * @author Ben Culkin - * - */ - public class DirectoryExpected extends RuntimeException { - private static final long serialVersionUID = 6614868098505684922L; - - /** - * Create a new exception. - * @param pth The path to the directory. - */ - public DirectoryExpected(String pth) { - super(String.format("Non-directory '%s' passed where a directory was expected", pth)); - } - } - private static final long serialVersionUID = 9078988253392361649L; private JEditorPane contentPane; @@ -79,25 +62,17 @@ public class FirmalBrowserPanel extends JPanel { navButtonPanel.setLayout(new GridLayout(2, 2)); SimpleKeyedButton firstButton = new SimpleKeyedButton("<< First"); - firstButton.setGlobalDefaultKeystroke("firstFile", "control shift P", (aev) -> { - moveFirst(); - }); + firstButton.setGlobalDefaultKeystroke("firstFile", "control shift P", (aev) -> moveFirst()); firstButton.setMnemonic(KeyEvent.VK_F); SimpleKeyedButton prevButton = new SimpleKeyedButton("< Previous"); - prevButton.setGlobalDefaultKeystroke("prevFile", "control P", (ev) -> { - movePrevious(); - }); + prevButton.setGlobalDefaultKeystroke("prevFile", "control P", (ev) -> movePrevious()); SimpleKeyedButton lastButton = new SimpleKeyedButton("Last >>"); - lastButton.setGlobalDefaultKeystroke("lastFile", "control shift N", (ev) -> { - moveLast(); - }); + lastButton.setGlobalDefaultKeystroke("lastFile", "control shift N", (ev) -> moveLast()); SimpleKeyedButton nextButton = new SimpleKeyedButton("Next >"); - nextButton.setGlobalDefaultKeystroke("nextFile", "control N", (ev) -> { - moveNext(); - }); + nextButton.setGlobalDefaultKeystroke("nextFile", "control N", (ev) -> moveNext()); navButtonPanel.add(firstButton); navButtonPanel.add(lastButton); diff --git a/firmal/src/main/java/module-info.java b/firmal/src/main/java/module-info.java new file mode 100644 index 0000000..80dd7c4 --- /dev/null +++ b/firmal/src/main/java/module-info.java @@ -0,0 +1,13 @@ +/** + * A browsing utility for images and other files. + * + * @author bjcul + * + */ +module firmal { + exports bjc.firmal; + + requires bjc.utils; + requires esodata; + requires transitive java.desktop; +}
\ No newline at end of file |
