mirror of
https://github.com/leozide/leocad.git
synced 2026-07-28 04:07:11 +00:00
Fix freeze for find/replace
The loop was not terminated properly if pieces were invisible. Fixes leozide/leocad#901
This commit is contained in:
+1
-4
@@ -4192,10 +4192,7 @@ void lcModel::FindReplacePiece(bool SearchForward, bool FindAll)
|
||||
|
||||
lcPiece* Current = mPieces[CurrentIdx];
|
||||
|
||||
if (!Current->IsVisible(mCurrentStep))
|
||||
continue;
|
||||
|
||||
if (PieceMatches(Current))
|
||||
if (Current->IsVisible(mCurrentStep) && PieceMatches(Current))
|
||||
{
|
||||
if (FindAll)
|
||||
Selection.Add(Current);
|
||||
|
||||
Reference in New Issue
Block a user