mirror of
				https://github.com/Drezil/imgui.git
				synced 2025-11-04 15:11:05 +01:00 
			
		
		
		
	Tests: Added hook/tweaks for imgui-test engine. + Fixed warnings.
This commit is contained in:
		@@ -2837,7 +2837,7 @@ bool ImGui::ItemAdd(const ImRect& bb, ImGuiID id, const ImRect* nav_bb_arg)
 | 
			
		||||
 | 
			
		||||
#ifdef IMGUI_ENABLE_TEST_ENGINE
 | 
			
		||||
    if (id != 0)
 | 
			
		||||
        ImGuiTestEngineHook_ItemAdd(&g, nav_bb_arg ? *nav_bb_arg : bb, id);
 | 
			
		||||
        IMGUI_TEST_ENGINE_ITEM_ADD(nav_bb_arg ? *nav_bb_arg : bb, id);
 | 
			
		||||
#endif
 | 
			
		||||
 | 
			
		||||
    // Clipping test
 | 
			
		||||
@@ -5544,6 +5544,10 @@ bool ImGui::Begin(const char* name, bool* p_open, ImGuiWindowFlags flags)
 | 
			
		||||
        window->DC.LastItemId = window->MoveId;
 | 
			
		||||
        window->DC.LastItemStatusFlags = IsMouseHoveringRect(title_bar_rect.Min, title_bar_rect.Max, false) ? ImGuiItemStatusFlags_HoveredRect : 0;
 | 
			
		||||
        window->DC.LastItemRect = title_bar_rect;
 | 
			
		||||
#ifdef IMGUI_ENABLE_TEST_ENGINE
 | 
			
		||||
        if (!(window->Flags & ImGuiWindowFlags_NoTitleBar))
 | 
			
		||||
            IMGUI_TEST_ENGINE_ITEM_ADD(window->DC.LastItemRect, window->DC.LastItemId);
 | 
			
		||||
#endif
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    PushClipRect(window->InnerClipRect.Min, window->InnerClipRect.Max, true);
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user