mirror of
https://github.com/godotengine/godot.git
synced 2025-11-10 10:31:15 +00:00
Consider TextEdit paste operation complex.
Not considering a paste operation as a complex one ends up
adding an unneeded extra step when pasting over a selection.
This fixes issue #18325
(cherry picked from commit b09e0454bb)
This commit is contained in:
parent
ae32bcf4c3
commit
10c12b37ec
1 changed files with 3 additions and 0 deletions
|
|
@ -4245,6 +4245,7 @@ void TextEdit::paste() {
|
||||||
|
|
||||||
String clipboard = OS::get_singleton()->get_clipboard();
|
String clipboard = OS::get_singleton()->get_clipboard();
|
||||||
|
|
||||||
|
begin_complex_operation();
|
||||||
if (selection.active) {
|
if (selection.active) {
|
||||||
|
|
||||||
selection.active = false;
|
selection.active = false;
|
||||||
|
|
@ -4261,6 +4262,8 @@ void TextEdit::paste() {
|
||||||
}
|
}
|
||||||
|
|
||||||
_insert_text_at_cursor(clipboard);
|
_insert_text_at_cursor(clipboard);
|
||||||
|
end_complex_operation();
|
||||||
|
|
||||||
update();
|
update();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue