mirror of
https://github.com/godotengine/godot.git
synced 2024-11-22 12:12:28 +00:00
[TextEdit / IME] Check selection before deleting to avoid unnecessary error messages.
This commit is contained in:
parent
0cd1483132
commit
315164c619
@ -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 New Issue
Block a user