13
0

forward-port generic MIDI and transport controllable changes from 2.X

git-svn-id: svn://localhost/ardour2/branches/3.0@13066 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Paul Davis 2012-07-23 13:31:51 +00:00
parent 0f79645be7
commit b2bbc44eaa
2 changed files with 6 additions and 4 deletions

View File

@ -3521,16 +3521,16 @@ ARDOUR_UI::TransportControllable::set_value (double val)
action = X_("Stop"); action = X_("Stop");
break; break;
case GotoStart: case GotoStart:
action = X_("Goto Start"); action = X_("GotoStart");
break; break;
case GotoEnd: case GotoEnd:
action = X_("Goto End"); action = X_("GotoEnd");
break; break;
case AutoLoop: case AutoLoop:
action = X_("Loop"); action = X_("Loop");
break; break;
case PlaySelection: case PlaySelection:
action = X_("Play Selection"); action = X_("PlaySelection");
break; break;
case RecordEnable: case RecordEnable:
action = X_("Record"); action = X_("Record");

View File

@ -234,7 +234,9 @@ MIDIControllable::midi_sense_note (Parser &, EventTwoBytes *msg, bool /*is_on*/)
} }
if (!controllable->is_toggle()) { if (!controllable->is_toggle()) {
controllable->set_value (midi_to_control (msg->note_number)); if (control_additional == msg->note_number) {
controllable->set_value (midi_to_control (msg->velocity));
}
} else { } else {
if (control_additional == msg->note_number) { if (control_additional == msg->note_number) {
controllable->set_value (controllable->get_value() > 0.5f ? 0.0f : 1.0f); controllable->set_value (controllable->get_value() > 0.5f ? 0.0f : 1.0f);