mirror of
https://github.com/zyedidia/micro.git
synced 2026-02-08 08:00:20 +09:00
Fix "no" when replacing with empty string (#2641)
* advance to end of found string when not replacing * simplify search location change
This commit is contained in:
@@ -853,8 +853,7 @@ func (h *BufPane) ReplaceCmd(args []string) {
|
||||
h.Cursor.Loc = searchLoc
|
||||
nreplaced++
|
||||
} else if !canceled && !yes {
|
||||
searchLoc = locs[0]
|
||||
searchLoc.X += util.CharacterCount(replace)
|
||||
searchLoc = locs[1]
|
||||
} else if canceled {
|
||||
h.Cursor.ResetSelection()
|
||||
h.Buf.RelocateCursors()
|
||||
|
||||
Reference in New Issue
Block a user