// In theory here we should assert that we are already at the right position, but it seems saner to just seek at the end and not assert/crash the user.
// In theory here we should assert that we are already at the right position, but it seems saner to just seek at the end and not assert/crash the user.
g.IO.KeyModsPrev=g.IO.KeyMods;// doing it here is better than in NewFrame() as we'll tolerate backend writing to KeyMods. If we want to firmly disallow it we should detect it.
// - Testing that only Alt is tested prevents Alt+Shift or AltGR from toggling menu layer.
// - AltGR is normally Alt+Ctrl but we can't reliably detect it (not all backends/systems/layout emit it as Alt+Ctrl). But even on keyboards without AltGR we don't want Alt+Ctrl to open menu anyway.
// Important: we don't assume that Alt was previously held in order to handle loss of focus when backend calls io.AddFocusEvent(false)
// Important: as before version <18314 we lacked an explicit IO event for focus gain/loss, we also compare mouse validity to detect old backends clearing mouse pos on focus loss.
Text("HoveredId: 0x%08X (%.2f sec), AllowOverlap: %d",g.HoveredIdPreviousFrame,g.HoveredIdTimer,g.HoveredIdAllowOverlap);// Not displaying g.HoveredId as it is update mid-frame
if(info->Desc[0]==0)// PushOverrideID() is often used to avoid hashing twice, which would lead to 2 calls to DebugHookIdInfo(). We prioritize the first one.
if(info->Desc[0]!=0)// PushOverrideID() is often used to avoid hashing twice, which would lead to 2 calls to DebugHookIdInfo(). We prioritize the first one.
if(info->QuerySuccess)// Source: GetID() hooks (prioritize over ItemInfo() because we frequently use patterns like: PushID(str), Button("") where they both have same id)
if(tool->StackLevel<tool->Results.Size)// Only start using fallback below when all queries are done, so during queries we don't flickering ??? markers.
MetricsHelpMarker("Hover an item with the mouse to display elements of the ID Stack leading to the item's final ID.\nEach level of the stack correspond to a PushID() call.\nAll levels of the stack are hashed together to make the final ID of a widget (ID displayed at the bottom level of the stack).\nRead FAQ entry about the ID stack for details.");
if(window)// Source: window name (because the root ID don't call GetID() and so doesn't get hooked)
Text("\"%s\" [window]",window->Name);
elseif(info->QuerySuccess)// Source: GetID() hooks (prioritize over ItemInfo() because we frequently use patterns like: PushID(str), Button("") where they both have same id)
TextUnformatted(info->Desc);
elseif(tool->StackLevel>=tool->Results.Size)// Only start using fallback below when all queries are done, so during queries we don't flickering ??? markers.
// (Integer encoded as XYYZZ for use in #if preprocessor conditionals. Work in progress versions typically starts at XYY99 then bounce up to XYY00, XYY01 etc. when release tagging happens)
IM_VEC4_CLASS_EXTRA// Define additional constructors and implicit cast operators in imconfig.h to convert back and forth between your math types and ImVec4.
#endif
@ -1327,6 +1327,7 @@ enum ImGuiHoveredFlags_
ImGuiHoveredFlags_AllowWhenBlockedByActiveItem=1<<7,// Return true even if an active item is blocking access to this item/window. Useful for Drag and Drop patterns.
ImGuiHoveredFlags_AllowWhenOverlapped=1<<8,// IsItemHovered() only: Return true even if the position is obstructed or overlapped by another window
ImGuiHoveredFlags_AllowWhenDisabled=1<<9,// IsItemHovered() only: Return true even if the item is disabled
ImGuiHoveredFlags_NoNavOverride=1<<10,// Disable using gamepad/keyboard navigation state when active, always query mouse.
ImGuiKeyDataKeysData[ImGuiKey_KeysData_SIZE];// Key state for all known keys. Use IsKeyXXX() functions to access this.
boolWantCaptureMouseUnlessPopupClose;// Alternative to WantCaptureMouse: (WantCaptureMouse == true && WantCaptureMouseUnlessPopupClose == false) when a click over void is expected to close a popup.
ImVec2MousePosPrev;// Previous mouse position (note that MouseDelta is not necessary == MousePos-MousePosPrev, in case either position is invalid)
voidSetBitRange(intn,intn2){n+=OFFSET;n2+=OFFSET;IM_ASSERT(n>=0&&n<BITCOUNT&&n2>n&&n2<=BITCOUNT);ImBitArraySetBitRange(Storage,n,n2);}// Works on range [n..n2)
boolQuerySuccess;// Obtained result from DebugHookIdInfo()
charDesc[58];// Arbitrarily sized buffer to hold a result (FIXME: could replace Results[] with a chunk stream?)
ImGuiDataTypeDataType:8;
charDesc[57];// Arbitrarily sized buffer to hold a result (FIXME: could replace Results[] with a chunk stream?) FIXME: Now that we added CTRL+C this should be fixed.
#pragma GCC diagnostic ignored "-Wformat-nonliteral" // warning: format not a string literal, format string not checked
#pragma GCC diagnostic ignored "-Wclass-memaccess" // [__GNUC__ >= 8] warning: 'memset/memcpy' clearing/writing an object of type 'xxxx' with no trivial copy-assignment; use assignment or value-initialization instead
#pragma GCC diagnostic ignored "-Wdeprecated-enum-enum-conversion" // warning: bitwise operation between different enumeration types ('XXXFlags_' and 'XXXFlagsPrivate_') is deprecated