]> ruin.nu Git - moosique.git/blobdiff - MooNote.java
YES!
[moosique.git] / MooNote.java
index 0449e86defed1375c30627c8e4db06dfdface6ea..2774c3052090a98bfadfc76a6156aba485189e6e 100644 (file)
@@ -134,7 +134,7 @@ public class MooNote extends MidiEvent {
         */
        public int getDuration() {
                if (!hasNoteOffEvent()) return 0;
-               return (int)(getTick() - noteOffEvent.getTick());
+               return (int)(noteOffEvent.getTick() - getTick());
        }
 
        /** 
@@ -142,6 +142,6 @@ public class MooNote extends MidiEvent {
         * @return      the note off MidiEvent
         */
        public boolean hasNoteOffEvent() {
-               return noteOffEvent == null;
+               return noteOffEvent != null;
        }
 }
\ No newline at end of file