mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-06 14:54:56 +01:00
launchpad Mini/X: tweak regex to account for weird cases
IRC user MikeLupe reports a Linux/ALSA system that has ports named Launchpad Mini MK3 LPMiniMK3 DA Launchpad Mini MK3 LPMiniMK3 MI (note the truncations). Unclear if this is a failure of some specific version of ALSA or something unusual about his device, but this should fix the situation without breaking for anyone else
This commit is contained in:
parent
07407c4e7c
commit
c628099814
1 changed files with 4 additions and 4 deletions
|
|
@ -121,9 +121,9 @@ LaunchPadX::probe (std::string& i, std::string& o)
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef LAUNCHPAD_MINI
|
#ifdef LAUNCHPAD_MINI
|
||||||
std::regex rx (X_("Launchpad Mini.*MIDI"));
|
std::regex rx (X_("Launchpad Mini.*MI"));
|
||||||
#else
|
#else
|
||||||
std::regex rx (X_("Launchpad X.*MIDI"));
|
std::regex rx (X_("Launchpad X.*MI"));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
auto has_lppro = [&rx](string const &s) {
|
auto has_lppro = [&rx](string const &s) {
|
||||||
|
|
@ -769,9 +769,9 @@ LaunchPadX::connect_daw_ports ()
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef LAUNCHPAD_MINI
|
#ifdef LAUNCHPAD_MINI
|
||||||
std::regex rx (X_("Launchpad Mini.*(DAW|MIDI 1)"), std::regex::extended);
|
std::regex rx (X_("Launchpad Mini.*(DAW|MIDI 1|DA$)"), std::regex::extended);
|
||||||
#else
|
#else
|
||||||
std::regex rx (X_("Launchpad X.*(DAW|MIDI 1)"), std::regex::extended);
|
std::regex rx (X_("Launchpad X.*(DAW|MIDI 1|DA$)"), std::regex::extended);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
auto is_dawport = [&rx](string const &s) {
|
auto is_dawport = [&rx](string const &s) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue