From eaf30808594778a90dca0e4319e678fc26532ea2 Mon Sep 17 00:00:00 2001 From: Matt Jenkins Date: Mon, 1 Oct 2018 11:11:10 +0100 Subject: [PATCH] Added jpg and gif coverart to book panel --- src/uk/co/majenko/audiobookrecorder/BookPanel.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/uk/co/majenko/audiobookrecorder/BookPanel.java b/src/uk/co/majenko/audiobookrecorder/BookPanel.java index ae42c73..eab6e51 100644 --- a/src/uk/co/majenko/audiobookrecorder/BookPanel.java +++ b/src/uk/co/majenko/audiobookrecorder/BookPanel.java @@ -38,6 +38,12 @@ public class BookPanel extends JPanel { genre = props.getProperty("book.genre"); comment = props.getProperty("book.comment"); File icon = new File(root, "coverart.png"); + if (!icon.exists()) { + icon = new File(root, "coverart.jpg"); + } + if (!icon.exists()) { + icon = new File(root, "coverart.gif"); + } if (icon.exists()) { cover = new ImageIcon(icon.getAbsolutePath()); resizedCover = Utils.getScaledImage(cover.getImage(), 75, 75);