mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-06 04:58:47 +02:00
ImGuiTextFilter: default parameter width=0.0f for no override, allow override with negative values
This commit is contained in:
@ -1283,10 +1283,10 @@ ImGuiTextFilter::ImGuiTextFilter(const char* default_filter)
|
||||
|
||||
void ImGuiTextFilter::Draw(const char* label, float width)
|
||||
{
|
||||
if (width > 0.0f)
|
||||
if (width != 0.0f)
|
||||
ImGui::PushItemWidth(width);
|
||||
ImGui::InputText(label, InputBuf, IM_ARRAYSIZE(InputBuf));
|
||||
if (width > 0.0f)
|
||||
if (width != 0.0f)
|
||||
ImGui::PopItemWidth();
|
||||
Build();
|
||||
}
|
||||
|
Reference in New Issue
Block a user