From 25efcb553c2d878b2733d30164a701560cb8f252 Mon Sep 17 00:00:00 2001 From: Matt Jenkins Date: Mon, 10 Sep 2018 22:44:16 +0100 Subject: [PATCH] Simplified icons --- .../audiobookrecorder/AudiobookRecorder.java | 7 --- .../co/majenko/audiobookrecorder/Icons.java | 63 +++++-------------- 2 files changed, 16 insertions(+), 54 deletions(-) diff --git a/src/uk/co/majenko/audiobookrecorder/AudiobookRecorder.java b/src/uk/co/majenko/audiobookrecorder/AudiobookRecorder.java index d4dc192..e26b5cf 100644 --- a/src/uk/co/majenko/audiobookrecorder/AudiobookRecorder.java +++ b/src/uk/co/majenko/audiobookrecorder/AudiobookRecorder.java @@ -189,14 +189,7 @@ public class AudiobookRecorder extends JFrame { window = this; - - Icons.loadIcons(); - -// initSphinx(); - - try { -// String clsname = "com.jtattoo.plaf.aluminium.AluminiumLookAndFeel"; String clsname = "com.jtattoo.plaf.hifi.HiFiLookAndFeel"; UIManager.setLookAndFeel(clsname); diff --git a/src/uk/co/majenko/audiobookrecorder/Icons.java b/src/uk/co/majenko/audiobookrecorder/Icons.java index e5df393..83c35c7 100644 --- a/src/uk/co/majenko/audiobookrecorder/Icons.java +++ b/src/uk/co/majenko/audiobookrecorder/Icons.java @@ -3,51 +3,20 @@ package uk.co.majenko.audiobookrecorder; import javax.swing.*; public class Icons { - static public ImageIcon book; - static public ImageIcon chapter; - static public ImageIcon sentence; - static public ImageIcon play; - static public ImageIcon playon; - static public ImageIcon stop; - static public ImageIcon record; - - static public ImageIcon openBook; - static public ImageIcon newBook; - static public ImageIcon newChapter; - static public ImageIcon recordRoom; - static public ImageIcon save; - - static public ImageIcon redo; - - static public ImageIcon fft; - static public ImageIcon peak; - - static public ImageIcon locked; - - static void loadIcons() { - book = new ImageIcon(Icons.class.getResource("icons/book.png")); - chapter = new ImageIcon(Icons.class.getResource("icons/chapter.png")); - sentence = new ImageIcon(Icons.class.getResource("icons/sentence.png")); - play = new ImageIcon(Icons.class.getResource("icons/play.png")); - playon = new ImageIcon(Icons.class.getResource("icons/playon.png")); - stop = new ImageIcon(Icons.class.getResource("icons/stop.png")); - record = new ImageIcon(Icons.class.getResource("icons/record.png")); - - openBook = new ImageIcon(Icons.class.getResource("icons/open.png")); - newBook = new ImageIcon(Icons.class.getResource("icons/new.png")); - newChapter = new ImageIcon(Icons.class.getResource("icons/new-chapter.png")); - recordRoom = new ImageIcon(Icons.class.getResource("icons/record-room.png")); - save = new ImageIcon(Icons.class.getResource("icons/save.png")); - - redo = new ImageIcon(Icons.class.getResource("icons/redo.png")); - - fft = new ImageIcon(Icons.class.getResource("icons/fft.png")); - peak = new ImageIcon(Icons.class.getResource("icons/peak.png")); - - locked = new ImageIcon(Icons.class.getResource("icons/locked.png")); - - - } + static public ImageIcon book = new ImageIcon(Icons.class.getResource("icons/book.png")); + static public ImageIcon chapter = new ImageIcon(Icons.class.getResource("icons/chapter.png")); + static public ImageIcon sentence = new ImageIcon(Icons.class.getResource("icons/sentence.png")); + static public ImageIcon play = new ImageIcon(Icons.class.getResource("icons/play.png")); + static public ImageIcon playon = new ImageIcon(Icons.class.getResource("icons/playon.png")); + static public ImageIcon stop = new ImageIcon(Icons.class.getResource("icons/stop.png")); + static public ImageIcon record = new ImageIcon(Icons.class.getResource("icons/record.png")); + static public ImageIcon openBook = new ImageIcon(Icons.class.getResource("icons/open.png")); + static public ImageIcon newBook = new ImageIcon(Icons.class.getResource("icons/new.png")); + static public ImageIcon newChapter = new ImageIcon(Icons.class.getResource("icons/new-chapter.png")); + static public ImageIcon recordRoom = new ImageIcon(Icons.class.getResource("icons/record-room.png")); + static public ImageIcon save = new ImageIcon(Icons.class.getResource("icons/save.png")); + static public ImageIcon redo = new ImageIcon(Icons.class.getResource("icons/redo.png")); + static public ImageIcon fft = new ImageIcon(Icons.class.getResource("icons/fft.png")); + static public ImageIcon peak = new ImageIcon(Icons.class.getResource("icons/peak.png")); + static public ImageIcon locked = new ImageIcon(Icons.class.getResource("icons/locked.png")); } - -