mirror of
https://github.com/godotengine/godot.git
synced 2025-01-23 02:52:28 -05:00
[TextEdit / IME] Check selection before deleting to avoid unnecessary error messages.
This commit is contained in:
parent
0cd1483132
commit
315164c619
1 changed files with 1 additions and 1 deletions
|
@ -1548,7 +1548,7 @@ void TextEdit::_notification(int p_what) {
|
|||
ime_text = DisplayServer::get_singleton()->ime_get_text();
|
||||
ime_selection = DisplayServer::get_singleton()->ime_get_selection();
|
||||
|
||||
if (!ime_text.is_empty()) {
|
||||
if (!ime_text.is_empty() && has_selection()) {
|
||||
delete_selection();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue