mirror of
https://github.com/ocornut/imgui.git
synced 2024-12-01 02:37:24 +01:00
Nav: Removed old unnecessary ifdefs.
This commit is contained in:
parent
f35734c925
commit
fb7cf4a475
@ -7653,9 +7653,7 @@ bool ImGui::ArrowButton(ImGuiID id, ImGuiDir dir, ImVec2 padding, ImGuiButtonFla
|
|||||||
bool pressed = ButtonBehavior(bb, id, &hovered, &held, flags);
|
bool pressed = ButtonBehavior(bb, id, &hovered, &held, flags);
|
||||||
|
|
||||||
const ImU32 col = GetColorU32((hovered && held) ? ImGuiCol_ButtonActive : hovered ? ImGuiCol_ButtonHovered : ImGuiCol_Button);
|
const ImU32 col = GetColorU32((hovered && held) ? ImGuiCol_ButtonActive : hovered ? ImGuiCol_ButtonHovered : ImGuiCol_Button);
|
||||||
#ifdef IMGUI_HAS_NAV
|
|
||||||
RenderNavHighlight(bb, id);
|
RenderNavHighlight(bb, id);
|
||||||
#endif
|
|
||||||
RenderFrame(bb.Min, bb.Max, col, true, style.FrameRounding);
|
RenderFrame(bb.Min, bb.Max, col, true, style.FrameRounding);
|
||||||
RenderTriangle(bb.Min + padding, dir, 1.0f);
|
RenderTriangle(bb.Min + padding, dir, 1.0f);
|
||||||
|
|
||||||
@ -12011,9 +12009,7 @@ bool ImGui::SplitterBehavior(ImGuiID id, const ImRect& bb, ImGuiAxis axis, float
|
|||||||
ImGuiWindow* window = g.CurrentWindow;
|
ImGuiWindow* window = g.CurrentWindow;
|
||||||
|
|
||||||
const ImGuiItemFlags item_flags_backup = window->DC.ItemFlags;
|
const ImGuiItemFlags item_flags_backup = window->DC.ItemFlags;
|
||||||
#ifdef IMGUI_HAS_NAV
|
|
||||||
window->DC.ItemFlags |= ImGuiItemFlags_NoNav | ImGuiItemFlags_NoNavDefaultFocus;
|
window->DC.ItemFlags |= ImGuiItemFlags_NoNav | ImGuiItemFlags_NoNavDefaultFocus;
|
||||||
#endif
|
|
||||||
bool add = ItemAdd(bb, id);
|
bool add = ItemAdd(bb, id);
|
||||||
window->DC.ItemFlags = item_flags_backup;
|
window->DC.ItemFlags = item_flags_backup;
|
||||||
if (!add)
|
if (!add)
|
||||||
|
Loading…
Reference in New Issue
Block a user