mirror of
				https://github.com/Drezil/imgui.git
				synced 2025-10-30 20:51:06 +01:00 
			
		
		
		
	Clipper: Fixed a bug if attempt to force-include a range which matches an already included range. (#3841)
This commit is contained in:
		| @@ -2975,13 +2975,15 @@ static bool ImGuiListClipper_StepInternal(ImGuiListClipper* clipper) | ||||
|     } | ||||
|  | ||||
|     // Step 0+ (if item height is given in advance) or 1+: Display the next range in line. | ||||
|     if (data->StepNo < data->Ranges.Size) | ||||
|     while (data->StepNo < data->Ranges.Size) | ||||
|     { | ||||
|         clipper->DisplayStart = ImMax(data->Ranges[data->StepNo].Min, already_submitted); | ||||
|         clipper->DisplayEnd = ImMin(data->Ranges[data->StepNo].Max, clipper->ItemsCount); | ||||
|         if (clipper->DisplayStart > already_submitted) //-V1051 | ||||
|             ImGuiListClipper_SeekCursorForItem(clipper, clipper->DisplayStart); | ||||
|         data->StepNo++; | ||||
|         if (clipper->DisplayStart == clipper->DisplayEnd && data->StepNo < data->Ranges.Size) | ||||
|             continue; | ||||
|         return true; | ||||
|     } | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user