g.NavWindowingToggleLayer&=(g.NavWindowingDisplayAlpha<1.0f);// Once button is held long enough we don't consider it a tag-to-toggle-layer press anymore.
g.NavWindowingToggleLayer&=(g.NavWindowingDisplayAlpha<1.0f);// Once button is held long enough we don't consider it a tag-to-toggle-layer press anymore.
// Select window to focus
// Select window to focus
// FIXME-NAVIGATION: Need to clarify input semantic, naming is misleading/incorrect here.
// FIXME-NAVIGATION: Need to clarify input semantic, naming is misleading/incorrect here.
// AllowOverlap mode (rarely used) requires previous frame HoveredId to be null or to match. This allows using patterns where a later submitted widget overlaps a previous one.
// AllowOverlap mode (rarely used) requires previous frame HoveredId to be null or to match. This allows using patterns where a later submitted widget overlaps a previous one.
@ -7136,47 +7199,6 @@ int ImGui::ParseFormatPrecision(const char* fmt, int default_precision)
delta/=100.0f;// Gamepad/keyboard tweak speeds in % of slider bounds
delta/=100.0f;// Gamepad/keyboard tweak speeds in % of slider bounds
if(IsKeyDownMap(ImGuiKey_NavTweakSlower))
if(IsNavInputDown(ImGuiNavInput_PadTweakSlow))
delta/=10.0f;
delta/=10.0f;
}
}
if(IsKeyDownMap(ImGuiKey_NavTweakFaster))
if(IsNavInputDown(ImGuiNavInput_PadTweakFast))
delta*=10.0f;
delta*=10.0f;
normalized_pos=ImSaturate(normalized_pos+delta);// FIXME-NAVIGATION: todo: cancel adjustment if current value already past edge and we are moving in edge direction, to avoid clamping value to edge.
normalized_pos=ImSaturate(normalized_pos+delta);// FIXME-NAVIGATION: todo: cancel adjustment if current value already past edge and we are moving in edge direction, to avoid clamping value to edge.
typedefintImGuiColorEditMode;// color edit mode for ColorEdit*() // enum ImGuiColorEditMode_
typedefintImGuiColorEditMode;// color edit mode for ColorEdit*() // enum ImGuiColorEditMode_
typedefintImGuiMouseCursor;// a mouse cursor identifier // enum ImGuiMouseCursor_
typedefintImGuiMouseCursor;// a mouse cursor identifier // enum ImGuiMouseCursor_
@ -437,7 +438,7 @@ namespace ImGui
IMGUI_APIboolIsKeyDown(intkey_index);// key_index into the keys_down[] array, imgui doesn't know the semantic of each entry, uses your own indices!
IMGUI_APIboolIsKeyDown(intkey_index);// key_index into the keys_down[] array, imgui doesn't know the semantic of each entry, uses your own indices!
IMGUI_APIboolIsKeyPressed(intkey_index,boolrepeat=true);// uses user's key indices as stored in the keys_down[] array. if repeat=true. uses io.KeyRepeatDelay / KeyRepeatRate
IMGUI_APIboolIsKeyPressed(intkey_index,boolrepeat=true);// uses user's key indices as stored in the keys_down[] array. if repeat=true. uses io.KeyRepeatDelay / KeyRepeatRate
IMGUI_APIboolIsKeyReleased(intkey_index);// "
IMGUI_APIboolIsKeyReleased(intkey_index);// "
IMGUI_APIintGetKeyPressedAmount(intkey_index,floatrepeat_delay,floatrate);// uses provided repeat rate/delay. return a count, typically 0 or 1 but may be >1 if RepeatRate is small enough that DeltaTime > RepeatRate
IMGUI_APIintGetKeyPressedAmount(intkey_index,floatrepeat_delay,floatrate);// uses provided repeat rate/delay. return a count, most often 0 or 1 but might be >1 if RepeatRate is small enough that DeltaTime > RepeatRate
IMGUI_APIboolIsMouseDown(intbutton);// is mouse button held
IMGUI_APIboolIsMouseDown(intbutton);// is mouse button held
IMGUI_APIboolIsMouseClicked(intbutton,boolrepeat=false);// did mouse button clicked (went from !Down to Down)
IMGUI_APIboolIsMouseClicked(intbutton,boolrepeat=false);// did mouse button clicked (went from !Down to Down)
IMGUI_APIboolIsMouseDoubleClicked(intbutton);// did mouse button double-clicked. a double-click returns false in IsMouseClicked(). uses io.MouseDoubleClickTime.
IMGUI_APIboolIsMouseDoubleClicked(intbutton);// did mouse button double-clicked. a double-click returns false in IsMouseClicked(). uses io.MouseDoubleClickTime.
@ -576,10 +577,10 @@ enum ImGuiSelectableFlags_
enumImGuiKey_
enumImGuiKey_
{
{
ImGuiKey_Tab,// for tabbing through fields
ImGuiKey_Tab,// for tabbing through fields
ImGuiKey_LeftArrow,// for text edit
ImGuiKey_RightArrow,// for text edit
ImGuiKey_UpArrow,// for text edit
ImGuiKey_UpArrow,// for text edit
ImGuiKey_DownArrow,// for text edit
ImGuiKey_DownArrow,// for text edit
ImGuiKey_LeftArrow,// for text edit
ImGuiKey_RightArrow,// for text edit
ImGuiKey_PageUp,
ImGuiKey_PageUp,
ImGuiKey_PageDown,
ImGuiKey_PageDown,
ImGuiKey_Home,// for text edit
ImGuiKey_Home,// for text edit
@ -594,27 +595,31 @@ enum ImGuiKey_
ImGuiKey_X,// for text edit CTRL+X: cut
ImGuiKey_X,// for text edit CTRL+X: cut
ImGuiKey_Y,// for text edit CTRL+Y: redo
ImGuiKey_Y,// for text edit CTRL+Y: redo
ImGuiKey_Z,// for text edit CTRL+Z: undo
ImGuiKey_Z,// for text edit CTRL+Z: undo
// Inputs for Gamepad/Keyboard navigation. Feed those buttons with the input of either or both peripherals involved.
ImGuiKey_NavActivate,// press button, tweak value // e.g. Space key, Circle button
ImGuiKey_NavCancel,// close menu/popup/child, unselect // e.g. Escape key, Cross button
ImGuiKey_NavInput,// text input // e.g. Enter key, Triangle button
ImGuiKey_NavMenu,// access menu, focus, move, resize // e.g. Square button
ImGuiKey_NavLeft,// e.g. Left arrow, D-Pad left
ImGuiKey_NavRight,// e.g. Right arrow, D-Pad right
ImGuiKey_NavUp,// e.g. Up arrow, D-Pad up
ImGuiKey_NavDown,// e.g. Down arrow, D-Pad down
ImGuiKey_NavScrollLeft,// e.g. Analog left
ImGuiKey_NavScrollRight,// e.g. Analog right
ImGuiKey_NavScrollUp,// e.g. Analog up
ImGuiKey_NavScrollDown,// e.g. Analog down
ImGuiKey_NavTweakFaster,// e.g. Shift key, R-trigger
ImGuiKey_NavTweakSlower,// e.g. Alt key, L-trigger
ImGuiKey_NavLast_,
ImGuiKey_COUNT
ImGuiKey_COUNT
};
};
enumImGuiNavInput_
{
ImGuiNavInput_PadActivate,// press button, tweak value // e.g. Circle button
ImGuiNavInput_PadCancel,// close menu/popup/child, lose selection // e.g. Cross button
ImGuiNavInput_PadInput,// text input // e.g. Triangle button
ImGuiNavInput_PadMenu,// access menu, focus, move, resize // e.g. Square button