GUI: ability to customize toggle button color

This commit is contained in:
tildearrow 2022-03-22 01:57:06 -05:00
parent 73d2f97274
commit f4f91ca49e
6 changed files with 46 additions and 20 deletions

View file

@ -137,16 +137,20 @@ void FurnaceGUI::drawSampleEdit() {
ImGui::BeginDisabled(sample->depth!=8 && sample->depth!=16);
ImGui::PushStyleColor(ImGuiCol_Button,TOGGLE_COLOR(!sampleDragMode));
if (ImGui::Button(ICON_FA_I_CURSOR "##SSelect")) {
sampleDragMode=false;
}
ImGui::PopStyleColor();
if (ImGui::IsItemHovered()) {
ImGui::SetTooltip("Edit mode: Select");
}
ImGui::SameLine();
ImGui::PushStyleColor(ImGuiCol_Button,TOGGLE_COLOR(sampleDragMode));
if (ImGui::Button(ICON_FA_PENCIL "##SDraw")) {
sampleDragMode=true;
}
ImGui::PopStyleColor();
if (ImGui::IsItemHovered()) {
ImGui::SetTooltip("Edit mode: Draw");
}