Browse Source

Add x-mark, ensure proper loading from both Eclipse and jarfile

Sam Jaffe 4 years ago
parent
commit
0d8a39e8c0

+ 1 - 2
src/main/lombok/org/leumasjaffe/recipe/view/TagInputPanel.java

@@ -13,7 +13,6 @@ import java.awt.FlowLayout;
 import java.awt.event.KeyEvent;
 import java.awt.event.KeyListener;
 import java.awt.image.BufferedImage;
-import java.io.File;
 import java.io.IOException;
 import java.util.HashSet;
 import java.util.Set;
@@ -33,7 +32,7 @@ public class TagInputPanel extends JPanel {
 	static {
 		BufferedImage tmp = null;
 		try {
-			tmp = ImageIO.read(new File("src/main/resources/x-mark.png"));
+			tmp = ImageIO.read(TagInputPanel.class.getResourceAsStream("/x-mark.png"));
 		} catch (IOException e) {
 			e.printStackTrace();
 		}

File diff suppressed because it is too large
+ 1 - 0
src/main/resources/x-mark.svg