mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-04 04:39:33 +01:00
editors for control protocols (generalized); editor for Generic MIDI that allows choosing a MIDI binding map (or none); support banking in binding URLs, and other miscellany related to generic MIDI; save+restore JACK_MidiPort connection state (but cause a crash at shutdown time)
git-svn-id: svn://localhost/ardour2/branches/3.0@6411 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
e10d0339cc
commit
77cc0f7cc8
17 changed files with 658 additions and 95 deletions
|
|
@ -21,7 +21,7 @@
|
|||
#include "midi++/port.h"
|
||||
|
||||
#include "midifunction.h"
|
||||
#include "control_protocol/basic_ui.h"
|
||||
#include "generic_midi_control_protocol.h"
|
||||
|
||||
using namespace MIDI;
|
||||
|
||||
|
|
@ -38,7 +38,7 @@ MIDIFunction::~MIDIFunction ()
|
|||
}
|
||||
|
||||
int
|
||||
MIDIFunction::init (BasicUI& ui, const std::string& function_name, MIDI::byte* sysex_data, size_t sysex_sz)
|
||||
MIDIFunction::init (GenericMidiControlProtocol& ui, const std::string& function_name, MIDI::byte* sysex_data, size_t sysex_sz)
|
||||
{
|
||||
if (strcasecmp (function_name.c_str(), "transport-stop") == 0) {
|
||||
_function = TransportStop;
|
||||
|
|
@ -56,6 +56,10 @@ MIDIFunction::init (BasicUI& ui, const std::string& function_name, MIDI::byte* s
|
|||
_function = TransportRecordEnable;
|
||||
} else if (strcasecmp (function_name.c_str(), "rec-disable") == 0) {
|
||||
_function = TransportRecordDisable;
|
||||
} else if (strcasecmp (function_name.c_str(), "next-bank") == 0) {
|
||||
_function = NextBank;
|
||||
} else if (strcasecmp (function_name.c_str(), "prev-bank") == 0) {
|
||||
_function = PrevBank;
|
||||
} else {
|
||||
return -1;
|
||||
}
|
||||
|
|
@ -75,6 +79,14 @@ void
|
|||
MIDIFunction::execute ()
|
||||
{
|
||||
switch (_function) {
|
||||
case NextBank:
|
||||
_ui->next_bank();
|
||||
break;
|
||||
|
||||
case PrevBank:
|
||||
_ui->prev_bank();
|
||||
break;
|
||||
|
||||
case TransportStop:
|
||||
_ui->transport_stop ();
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue