Browse Source

Merge pull request #2276 from kallisto56/master

Fix cursor swap in `QuickFind.SelectAllMatches()`
Brian Fiete 2 weeks ago
parent
commit
266711c05a
1 changed files with 2 additions and 2 deletions
  1. 2 2
      IDE/src/ui/QuickFind.bf

+ 2 - 2
IDE/src/ui/QuickFind.bf

@@ -279,7 +279,7 @@ namespace IDE.ui
 
 			bool Matches(int32 idx)
 			{
-				if (idx + findText.Length >= ewc.mData.mTextLength)
+				if (idx + findText.Length > ewc.mData.mTextLength)
 					return false;
 
 				for (var i = 0; i < findText.Length; i++)
@@ -352,7 +352,7 @@ namespace IDE.ui
 			if (swapCursor != null)
 			{
 				Swap!(primaryCursor.mCursorTextPos, swapCursor.mCursorTextPos);
-				Swap!(primaryCursor.mSelection.Value, swapCursor.mSelection.Value);
+				Swap!(primaryCursor.mSelection.ValueRef, swapCursor.mSelection.ValueRef);
 			}
 
 			return (!isFirstMatch);