X-Git-Url: https://ruin.nu/git/?a=blobdiff_plain;f=Moosique.java;h=9b4349c9acbb9db040a1f8bd0d1b1c6d75225853;hb=c87df9f217c5730ae465252b415bb7e52a4f3fed;hp=0a148b60a3acf0ae2422d98f902f22947cb3b26d;hpb=867eb267809ea85e6f983b93e5f63ca86150d7bc;p=moosique.git diff --git a/Moosique.java b/Moosique.java index 0a148b6..9b4349c 100644 --- a/Moosique.java +++ b/Moosique.java @@ -74,7 +74,7 @@ public class Moosique { // Builds GUI, unless n-flag is set. if (makeGUI) { - System.out.print("Building GUI..."); + System.out.print("Building GUI."); try { UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); } catch (Exception e) {} @@ -182,6 +182,9 @@ public class Moosique { */ public static void resume() { gui.update(0); + try { + sequencer.setSequence(seq); + } catch (InvalidMidiDataException e) {} sequencer.start(); // Disables input to volatile components @@ -312,8 +315,8 @@ public class Moosique { } /** - * Shows the given message in the status bar. - * @param text the message to show + * Returns whether the given track should be drawn + * @return true if the given track should be drawn */ public static boolean shouldBeDrawn(Track track) { if (drawEmptyTracks) return true; @@ -322,8 +325,8 @@ public class Moosique { /** - * Shows the given message in the status bar. - * @param text the message to show + * Sets whether empty tracks should be drawn + * @param state true if empty tracks should be drawn */ public static void setDrawEmptyTracks(boolean state) { drawEmptyTracks = state; @@ -391,7 +394,7 @@ public class Moosique { Collections.sort(noteOns, c); Collections.sort(noteOffs, c); - // For each NoteOn event, finds its NoteOff event and replaces it with a MooNote. + // Replaces each NoteOn event it with a MooNote containing a reference to the NoteOff event. Iterator iOn = noteOns.iterator(), iOff; MidiEvent on, off = null, nextOff; ShortMessage onMsg, nextOffMsg; @@ -420,7 +423,6 @@ public class Moosique { iOn.remove(); } } - // Sends sequence to GUI and sequencer, then returns if (gui != null) gui.setSequence(seq); try {