GUI: add all/none buttons to ins selector

This commit is contained in:
tildearrow 2022-06-05 23:44:52 -05:00
parent b8c785230e
commit 1778362933

View file

@ -3822,6 +3822,18 @@ bool FurnaceGUI::loop() {
ImGui::Text("this is an instrument bank! select which one to use:");
} else {
ImGui::Text("this is an instrument bank! select which ones to load:");
ImGui::SameLine();
if (ImGui::Button("All")) {
for (std::pair<DivInstrument*,bool>& i: pendingIns) {
i.second=true;
}
}
ImGui::SameLine();
if (ImGui::Button("None")) {
for (std::pair<DivInstrument*,bool>& i: pendingIns) {
i.second=false;
}
}
}
bool anySelected=false;
float sizeY=ImGui::GetFrameHeightWithSpacing()*pendingIns.size();