Added showing a double used note in MIDI drum note menu.

dev
Holger Wirtz 2 years ago
parent 9ae5915738
commit d809ebba6c
  1. 16
      UI.hpp

@ -4282,6 +4282,14 @@ void UI_func_drum_reverb_send(uint8_t param) {
}
}
bool _get_midi_note(uint8_t note) {
for (uint8_t i = DRUMS_MIDI_NOTE_MIN; i <= DRUMS_MIDI_NOTE_MAX; i++) {
if (configuration.drums.drum_midi_note[activesample] == i)
return (true);
}
return (false);
}
void _UI_func_drum_midi_note_display(bool mode) {
char temp1[10];
char temp2[10];
@ -4294,10 +4302,16 @@ void _UI_func_drum_midi_note_display(bool mode) {
if (mode == false) {
snprintf_P(temp1, sizeof(temp1), PSTR("[%02d]"), activesample + 1);
if (_get_midi_note == true)
snprintf_P(temp2, sizeof(temp2), PSTR(" %-3s*"), note_name);
else
snprintf_P(temp2, sizeof(temp2), PSTR(" %-3s "), note_name);
} else {
snprintf_P(temp1, sizeof(temp1), PSTR(" %02d "), activesample + 1);
snprintf_P(temp2, sizeof(temp2), PSTR("[%-3s]"), note_name);
if (_get_midi_note == true)
snprintf_P(temp2, sizeof(temp2), PSTR("<%-3s>"), note_name);
else
snprintf_P(temp2, sizeof(temp2), PSTR(" %-3s*"), note_name);
}
display.show(1, 0, 4, temp1);
display.show(1, 4, 7, basename(drum_config[activesample].name));

Loading…
Cancel
Save