mirror of
				https://github.com/Drezil/imgui.git
				synced 2025-10-31 13:11:05 +01:00 
			
		
		
		
	Popups: Fixed an issue when reopening a same popup multiple times would offset them by 1 pixel on the right. (#4936)
Passing explicit ImGuiPopupFlags_MouseButtonRight to OpenPopupOnItemClick() calls somehow document the unusual (due to legacy) default value.
This commit is contained in:
		| @@ -7570,8 +7570,8 @@ static void ShowExampleAppCustomRendering(bool* p_open) | ||||
|  | ||||
|             // Context menu (under default mouse threshold) | ||||
|             ImVec2 drag_delta = ImGui::GetMouseDragDelta(ImGuiMouseButton_Right); | ||||
|             if (opt_enable_context_menu && ImGui::IsMouseReleased(ImGuiMouseButton_Right) && drag_delta.x == 0.0f && drag_delta.y == 0.0f) | ||||
|                 ImGui::OpenPopupOnItemClick("context"); | ||||
|             if (opt_enable_context_menu && drag_delta.x == 0.0f && drag_delta.y == 0.0f) | ||||
|                 ImGui::OpenPopupOnItemClick("context", ImGuiPopupFlags_MouseButtonRight); | ||||
|             if (ImGui::BeginPopup("context")) | ||||
|             { | ||||
|                 if (adding_line) | ||||
|   | ||||
		Reference in New Issue
	
	Block a user