Skip to content

Commit

Permalink
Merge pull request #72261 from Paulb23/preserve-carets-search
Browse files Browse the repository at this point in the history
Fixed removing secondary carets when editing with search open
  • Loading branch information
akien-mga authored Jan 29, 2023
2 parents 0d36281 + 8cb05a5 commit d866d6c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion editor/code_editor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,9 @@ void FindReplaceBar::unhandled_input(const Ref<InputEvent> &p_event) {
}

bool FindReplaceBar::_search(uint32_t p_flags, int p_from_line, int p_from_col) {
text_editor->remove_secondary_carets();
if (!preserve_cursor) {
text_editor->remove_secondary_carets();
}
String text = get_search_text();
Point2i pos = text_editor->search(text, p_flags, p_from_line, p_from_col);

Expand Down

0 comments on commit d866d6c

Please sign in to comment.