IM_ASSERT(ImGui::IsNamedKeyOrModKey(key));// Backend needs to pass a valid ImGuiKey_ constant. 0..511 values are legacy native key codes which are not accepted by this API.
IM_ASSERT(ImGui::IsNamedKeyOrModKey(key));// Backend needs to pass a valid ImGuiKey_ constant. 0..511 values are legacy native key codes which are not accepted by this API.
IM_ASSERT(!ImGui::IsAliasKey(key));// Backend cannot submit ImGuiKey_MouseXXX values they are automatically inferred from AddMouseXXX() events.
IM_ASSERT(ImGui::IsAliasKey(key)==false);// Backend cannot submit ImGuiKey_MouseXXX values they are automatically inferred from AddMouseXXX() events.
IM_ASSERT(key!=ImGuiMod_Shortcut);// We could easily support the translation here but it seems saner to not accept it (TestEngine perform a translation itself)
IM_ASSERT(key!=ImGuiMod_Shortcut);// We could easily support the translation here but it seems saner to not accept it (TestEngine perform a translation itself)
// Verify that backend isn't mixing up using new io.AddKeyEvent() api and old io.KeysDown[] + io.KeyMap[] data.
// Verify that backend isn't mixing up using new io.AddKeyEvent() api and old io.KeysDown[] + io.KeyMap[] data.
IM_ASSERT((IsNamedKey(key)||key==ImGuiKey_None)&&"Support for user key indices was dropped in favor of ImGuiKey. Please update backend and user code.");
IM_ASSERT((IsNamedKey(key)||key==ImGuiKey_None)&&"Support for user key indices was dropped in favor of ImGuiKey. Please update backend and user code.");
IM_ASSERT(IsNamedKeyOrModKey(key)&&(owner_id!=ImGuiKeyOwner_Any||(flags&(ImGuiInputFlags_LockThisFrame|ImGuiInputFlags_LockUntilRelease))));// Can only use _Any with _LockXXX flags (to eat a key away without an ID to retrieve it)
IM_ASSERT(IsNamedKeyOrModKey(key)&&(owner_id!=ImGuiKeyOwner_Any||(flags&(ImGuiInputFlags_LockThisFrame|ImGuiInputFlags_LockUntilRelease))));// Can only use _Any with _LockXXX flags (to eat a key away without an ID to retrieve it)
IM_ASSERT((flags&~ImGuiInputFlags_SupportedBySetKeyOwner)==0);// Passing flags not supported by this function!
IM_ASSERT((flags&~ImGuiInputFlags_SupportedBySetKeyOwner)==0);// Passing flags not supported by this function!
IMGUI_APIvoidSetItemKeyOwner(ImGuiKeykey,ImGuiInputFlagsflags=0);// Set key owner to last item if it is hovered or active. Equivalent to 'if (IsItemHovered() || IsItemActive()) { SetKeyOwner(key, GetItemID());'.
IMGUI_APIvoidSetItemKeyOwner(ImGuiKeykey,ImGuiInputFlagsflags=0);// Set key owner to last item if it is hovered or active. Equivalent to 'if (IsItemHovered() || IsItemActive()) { SetKeyOwner(key, GetItemID());'.
IMGUI_APIboolTestKeyOwner(ImGuiKeykey,ImGuiIDowner_id);// Test that key is either not owned, either owned by 'owner_id'
IMGUI_APIboolTestKeyOwner(ImGuiKeykey,ImGuiIDowner_id);// Test that key is either not owned, either owned by 'owner_id'