Skip to content

Commit

Permalink
[#37] Decrementing nextColumn below 0 will freeze the program
Browse files Browse the repository at this point in the history
  • Loading branch information
tpecholt committed Sep 22, 2024
1 parent c1cfadf commit 314d3ed
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/node.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1749,19 +1749,23 @@ bool Widget::PropertyUI(int i, UIContext& ctx)
ImGui::EndDisabled();
break;
case 12:
{
ImGui::BeginDisabled(!snapSides);
ImGui::Text("nextColumn");
ImGui::TableNextColumn();
ImGui::SetNextItemWidth(-ImGui::GetFrameHeight());
if (ImGui::InputInt("##nextColumn", nextColumn.access())) {
int tmp = nextColumn;
if (ImGui::InputInt("##nextColumn", &tmp) && tmp >= 0) {
changed = true;
nextColumn = tmp;
if (nextColumn) {
sameLine = false;
spacing = 0;
}
}
ImGui::EndDisabled();
break;
}
case 13:
ImGui::BeginDisabled(!snapSides);
ImGui::Text("allowOverlap");
Expand Down

0 comments on commit 314d3ed

Please sign in to comment.