Fix bounce_range_selection trigger slot dropdown

This commit is contained in:
Robin Gareus 2022-02-10 00:42:26 +01:00
parent 19b844e054
commit 46b8b0963e
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04

View File

@ -4198,7 +4198,8 @@ Editor::bounce_range_selection (BounceTarget target, bool enable_processing)
for (int c = 0; c < default_triggers_per_box; ++c) {
// XXX ('A' + x) is not translatable, TODO abstract using nth_letter()
tslot->AddMenuElem (Menu_Helpers::MenuElem (string_compose ("%1", (char)('A' + c)), sigc::bind ([] (uint32_t* t, uint32_t v) {*t = v;}, &trigger_slot, c)));
std::string lbl = string_compose ("%1", (char)('A' + c));
tslot->AddMenuElem (Menu_Helpers::MenuElem (lbl, sigc::bind ([] (uint32_t* t, uint32_t v, ArdourDropdown* s, std::string l) {*t = v; s->set_text (l);}, &trigger_slot, c, tslot, lbl)));
}
tslot->set_active ("A");