buffer/replace: Advance match index on each replace. (#2992)

Release Notes:
- Fixed "Replace next" not advancing the match index.
This commit is contained in:
Piotr Osiewicz 2023-09-19 23:56:22 +02:00 committed by GitHub
parent ae019fb7d3
commit 4525509804
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -925,6 +925,7 @@ impl BufferSearchBar {
Some(self.replacement(cx)).filter(|rep| !rep.is_empty()),
);
searchable_item.replace(&matches[active_index], &query, cx);
self.select_next_match(&SelectNextMatch, cx);
}
self.focus_editor(&FocusEditor, cx);