From 5e3d4ae044d32e263eb004630d317470f2a9cc28 Mon Sep 17 00:00:00 2001 From: 4pr0n Date: Sun, 25 May 2014 20:10:49 -0700 Subject: [PATCH] Overwrite config is set immediately --- src/main/java/com/rarchives/ripme/ui/MainWindow.java | 6 ++++++ src/main/java/com/rarchives/ripme/utils/RipUtils.java | 1 - 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/rarchives/ripme/ui/MainWindow.java b/src/main/java/com/rarchives/ripme/ui/MainWindow.java index ff719990..2b448548 100644 --- a/src/main/java/com/rarchives/ripme/ui/MainWindow.java +++ b/src/main/java/com/rarchives/ripme/ui/MainWindow.java @@ -481,6 +481,12 @@ public class MainWindow implements Runnable, RipStatusHandler { Utils.setConfigString("rips.directory", chosenPath); } }); + configOverwriteCheckbox.addActionListener(new ActionListener() { + @Override + public void actionPerformed(ActionEvent arg0) { + Utils.setConfigBoolean("file.overwrite", configOverwriteCheckbox.isSelected()); + } + }); } private void setupTrayIcon() { diff --git a/src/main/java/com/rarchives/ripme/utils/RipUtils.java b/src/main/java/com/rarchives/ripme/utils/RipUtils.java index 3053614b..a06ad328 100644 --- a/src/main/java/com/rarchives/ripme/utils/RipUtils.java +++ b/src/main/java/com/rarchives/ripme/utils/RipUtils.java @@ -12,7 +12,6 @@ import org.apache.log4j.Logger; import org.jsoup.Jsoup; import org.jsoup.nodes.Document; import org.jsoup.nodes.Element; -import org.jsoup.select.Elements; import com.rarchives.ripme.ripper.AbstractRipper; import com.rarchives.ripme.ripper.rippers.ImgurRipper;