Hide "Midi Through" on Linux only

Note HAVE_ALSA is mandatory for Linux builds, even when only
using JACK.
This commit is contained in:
Robin Gareus 2021-01-18 15:36:01 +01:00
parent c02169a6c8
commit 528cf92ed5
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04

View File

@ -1579,10 +1579,11 @@ PortManager::fill_midi_port_info_locked ()
flags = MidiPortFlags(MidiPortSelection | MidiPortMusic);
}
// TODO Linux only
#ifdef HAVE_ALSA
if ((*p).find (X_("Midi Through")) != string::npos || (*p).find (X_("Midi-Through")) != string::npos) {
flags = MidiPortFlags (flags | MidiPortVirtual);
}
#endif
if (flags != MidiPortFlags (0)) {
_port_info[pid].properties = flags;
@ -1608,10 +1609,11 @@ PortManager::fill_midi_port_info_locked ()
flags = MidiPortControl;
}
// TODO Linux only
#ifdef HAVE_ALSA
if ((*p).find (X_("Midi Through")) != string::npos || (*p).find (X_("Midi-Through")) != string::npos) {
flags = MidiPortFlags (flags | MidiPortVirtual);
}
#endif
if (flags != MidiPortFlags (0)) {
_port_info[pid].properties = flags;