Skip to content

Commit

Permalink
Use the ModIndex of the displayed LFO, not the selected Source (#5031)
Browse files Browse the repository at this point in the history
WHen drawing the LFO display we picked the wrong mod index in several
cases

Closes #5029
  • Loading branch information
baconpaul authored Sep 8, 2021
1 parent f06d224 commit 206a4d1
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/gui/SurgeGUIEditor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4526,7 +4526,11 @@ SurgeGUIEditor::layoutComponentForSkin(std::shared_ptr<Surge::GUI::Skin::Control
lfoDisplay->setTag(p->id + start_paramtags);
lfoDisplay->setLFOStorage(&synth->storage.getPatch().scene[current_scene].lfo[lfo_id]);
lfoDisplay->setModSource((modsources)p->ctrlgroup_entry);
lfoDisplay->setModIndex(modsource_index);

auto msi = 0;
if (gui_modsrc[p->ctrlgroup_entry])
msi = gui_modsrc[p->ctrlgroup_entry]->getCurrentModIndex();
lfoDisplay->setModIndex(msi);
lfoDisplay->setStorage(&synth->storage);
lfoDisplay->setStepSequencerStorage(
&synth->storage.getPatch().stepsequences[current_scene][lfo_id]);
Expand Down

0 comments on commit 206a4d1

Please sign in to comment.