fix one-frame glitch
This commit is contained in:
parent
e14015b09f
commit
f09c263d2c
2
TODO.md
2
TODO.md
|
@ -1,4 +1,4 @@
|
||||||
# to-do for 0.6.5
|
# to-do for 0.6.6
|
||||||
|
|
||||||
- fix possible issues when moving selection
|
- fix possible issues when moving selection
|
||||||
- fix Metal intro crash
|
- fix Metal intro crash
|
||||||
|
|
|
@ -2152,7 +2152,12 @@ void FurnaceGUI::drawMacros(std::vector<FurnaceGUIMacroDesc>& macros, FurnaceGUI
|
||||||
switch (settings.macroLayout) {
|
switch (settings.macroLayout) {
|
||||||
case 0: {
|
case 0: {
|
||||||
if (ImGui::BeginTable("MacroSpace",2)) {
|
if (ImGui::BeginTable("MacroSpace",2)) {
|
||||||
ImGui::TableSetupColumn("c0",ImGuiTableColumnFlags_WidthFixed,0.0);
|
float precalcWidth=0.0f;
|
||||||
|
for (FurnaceGUIMacroDesc& i: macros) {
|
||||||
|
float next=ImGui::CalcTextSize(i.displayName).x+ImGui::GetStyle().ItemInnerSpacing.x*2.0f+ImGui::CalcTextSize(ICON_FA_CHEVRON_UP).x+ImGui::GetStyle().ItemSpacing.x*2.0f;
|
||||||
|
if (next>precalcWidth) precalcWidth=next;
|
||||||
|
}
|
||||||
|
ImGui::TableSetupColumn("c0",ImGuiTableColumnFlags_WidthFixed,MAX(120.0f*dpiScale,precalcWidth));
|
||||||
ImGui::TableSetupColumn("c1",ImGuiTableColumnFlags_WidthStretch,0.0);
|
ImGui::TableSetupColumn("c1",ImGuiTableColumnFlags_WidthStretch,0.0);
|
||||||
ImGui::TableNextRow();
|
ImGui::TableNextRow();
|
||||||
ImGui::TableNextColumn();
|
ImGui::TableNextColumn();
|
||||||
|
|
Loading…
Reference in a new issue