summaryrefslogtreecommitdiff
path: root/gtk2_ardour/midi_region_view.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2010-06-24 21:22:00 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2010-06-24 21:22:00 +0000
commitdb55b149eb6b65bc3efa723ebe266f1035bb702f (patch)
tree7335adba1e762a3ab80a732655e6d7b932c59b67 /gtk2_ardour/midi_region_view.cc
parent806a22fefe8bc79c0307a6c3f6bfbde1185e7574 (diff)
change the way MIDI note colors are defined (2 3-point color ranges, one for selected, one for unselected); change default scroll action on selected midi notes to "fine" adjustment rather than "coarse" (now alt-scroll)
git-svn-id: svn://localhost/ardour2/branches/3.0@7302 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/midi_region_view.cc')
-rw-r--r--gtk2_ardour/midi_region_view.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/gtk2_ardour/midi_region_view.cc b/gtk2_ardour/midi_region_view.cc
index 35c3766410..5eb6e55c9f 100644
--- a/gtk2_ardour/midi_region_view.cc
+++ b/gtk2_ardour/midi_region_view.cc
@@ -525,7 +525,7 @@ MidiRegionView::scroll (GdkEventScroll* ev)
trackview.editor().hide_verbose_canvas_cursor ();
- bool fine = Keyboard::modifier_state_equals (ev->state, Keyboard::SecondaryModifier);
+ bool fine = !Keyboard::modifier_state_equals (ev->state, Keyboard::SecondaryModifier);
if (ev->direction == GDK_SCROLL_UP) {
change_velocities (true, fine, false);
@@ -2068,7 +2068,7 @@ MidiRegionView::begin_resizing (bool /*at_front*/)
// calculate color based on note velocity
resize_rect->property_fill_color_rgba() = UINT_INTERPOLATE(
- CanvasNoteEvent::meter_style_fill_color(note->note()->velocity()),
+ CanvasNoteEvent::meter_style_fill_color(note->note()->velocity(), note->selected()),
fill_color,
0.85);
@@ -2227,7 +2227,7 @@ MidiRegionView::change_note_velocity(CanvasNoteEvent* event, int8_t velocity, bo
new_velocity = velocity;
}
- // event->show_velocity ();
+ event->set_selected (event->selected()); // change color
diff_add_change (event, MidiModel::DiffCommand::Velocity, new_velocity);
}