diff options
Diffstat (limited to 'scene/gui/rich_text_label.cpp')
-rw-r--r-- | scene/gui/rich_text_label.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/scene/gui/rich_text_label.cpp b/scene/gui/rich_text_label.cpp index 124c268c8a..9cf4c105b4 100644 --- a/scene/gui/rich_text_label.cpp +++ b/scene/gui/rich_text_label.cpp @@ -793,6 +793,17 @@ void RichTextLabel::_gui_input(Ref<InputEvent> p_event) { selection.click = item; selection.click_char = line; + + // Erase previous selection. + if (selection.active) { + selection.from = NULL; + selection.from_char = NULL; + selection.to = NULL; + selection.to_char = NULL; + selection.active = false; + + update(); + } } } |