THE MEGA-FORMATTING COMMIT! TABS RULE, SPACES DROOL

This commit is contained in:
Wirlaburla 2024-07-22 18:19:38 -05:00
parent 6e292212fd
commit 408a52512b
15 changed files with 3084 additions and 3093 deletions

View File

@ -98,9 +98,7 @@ public class Ernie implements ActionListener {
});
frame.setVisible(true);
} else { System.out.println("Updater: No updates."); }
} catch (IOException ex) {
Logger.getLogger(Ernie.class.getName()).log(Level.SEVERE, null, ex);
} catch (JSONException ex) {
} catch (IOException | JSONException ex) {
Logger.getLogger(Ernie.class.getName()).log(Level.SEVERE, null, ex);
}
}

View File

@ -16,7 +16,6 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
public class FirescriptFormatException extends Exception {
public FirescriptFormatException() {
super();

View File

@ -16,9 +16,6 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import com.github.difflib.DiffUtils;
import com.github.difflib.UnifiedDiffUtils;
import com.github.difflib.patch.Patch;
import net.lingala.zip4j.ZipFile;
import javax.swing.*;
@ -35,9 +32,6 @@ import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.concurrent.TimeUnit;
import java.util.logging.Level;
import java.util.logging.Logger;
import java.util.stream.Stream;
public class Gonzo {
JFrame frame = new JFrame();
@ -354,11 +348,8 @@ public class Gonzo {
});
}
private static void listAllFiles(Path currentPath, List<String> allFiles)
throws IOException
{
try (DirectoryStream<Path> stream = Files.newDirectoryStream(currentPath))
{
private static void listAllFiles(Path currentPath, List<String> allFiles) throws IOException {
try (DirectoryStream<Path> stream = Files.newDirectoryStream(currentPath)) {
for (Path entry : stream) {
if (Files.isDirectory(entry)) {
listAllFiles(entry, allFiles);

View File

@ -284,13 +284,14 @@ public class MissPiggy implements ActionListener {
System.out.println("Initializing modList to GUI with length of " + Main.Mods.size() + " units"); //debug
while (i < Main.Mods.size()) {
if (Main.Mods.get(i).friendlyName == null || Main.Mods.get(i).friendlyName.isEmpty())
{Main.Mods.get(i).friendlyName = Main.Mods.get(i).path;}
Main.Mods.get(i).friendlyName = Main.Mods.get(i).path;
if (Main.Mods.get(i).enabled) {contents[i] = Main.Mods.get(i).friendlyName;}
else {contents[i] = Main.Mods.get(i).friendlyName + " (Disabled)";}
//debug
String authorDisplay;
if (Main.Mods.get(i).author == null || Main.Mods.get(i).author.isEmpty()) {authorDisplay = "Anonymous";} else {authorDisplay = "\"" + Main.Mods.get(i).author + "\"";}
if (Main.Mods.get(i).author == null || Main.Mods.get(i).author.isEmpty()) {authorDisplay = "Anonymous";}
else {authorDisplay = "\"" + Main.Mods.get(i).author + "\"";}
System.out.println("Added " + Main.Mods.get(i).friendlyName + " by " + authorDisplay);
i++;
@ -593,7 +594,6 @@ public class MissPiggy implements ActionListener {
int result = JOptionPane.showConfirmDialog(frame, "Firestar encountered an internal error.\n" + ex.getMessage(), "Fatal Error", JOptionPane.DEFAULT_OPTION, JOptionPane.ERROR_MESSAGE);
if (result == JOptionPane.OK_OPTION) {System.exit(1);} //user safety
}
}
});
}

View File

@ -5,7 +5,7 @@ import java.util.Iterator;
import java.util.LinkedList;
import java.util.Queue;
/**
/*
* Created by simon on 8/29/17.
* Copyright 2017 Simon Haoran Liang
*
@ -130,8 +130,7 @@ public class ReplacingInputStream extends FilterInputStream {
}
b[off + i] = (byte)c;
}
} catch (IOException ee) {
}
} catch (IOException ee) { }
return i;
}
}

View File

@ -297,9 +297,13 @@ public class Suggs implements ActionListener, ListSelectionListener {
String dTitleInList; // avoid editing the actual list
String dArtistInList; // otherwise we cause weird JTextField behavior
if (tracklist.get(i).title == null || tracklist.get(i).title.isEmpty())
{dTitleInList = tracklist.get(i).path.getName();} else {dTitleInList = tracklist.get(i).title;}
dTitleInList = tracklist.get(i).path.getName();
else
dTitleInList = tracklist.get(i).title;
if (tracklist.get(i).artist == null || tracklist.get(i).artist.isEmpty())
{dArtistInList = "Unknown Artist";} else {dArtistInList = tracklist.get(i).artist;}
dArtistInList = "Unknown Artist";
else
dArtistInList = tracklist.get(i).artist;
contents[i] = dArtistInList + " - " + dTitleInList;
i++;