fix for short notes being displayed as infinitely long.
authornick_m <mainsbridge@gmail.com>
Sun, 20 Nov 2016 13:17:31 +0000 (00:17 +1100)
committernick_m <mainsbridge@gmail.com>
Sun, 20 Nov 2016 13:17:31 +0000 (00:17 +1100)
gtk2_ardour/midi_region_view.cc

index 9ac308d140f4a782540c75b8c5600fb0971d32e2..853294eb83de831949023040a4155fd764ad2ceb 100644 (file)
@@ -1704,7 +1704,7 @@ MidiRegionView::update_sustained (Note* ev, bool update_ghost_regions)
        double y1;
 
        /* trim note display to not overlap the end of its region */
-       if (note->length() > 0) {
+       if (note->length().to_double() > 0.0) {
                double note_end_time = note->end_time().to_double();
 
                if (note_end_time > mr->start_beats() + mr->length_beats()) {