From 4293f76cf104027c7ded89fc6d3d0ce11a758fb0 Mon Sep 17 00:00:00 2001 From: Haoyu Qiu Date: Wed, 8 Jan 2020 21:01:08 +0800 Subject: [PATCH] Emits meta_hover_ended when mouse exit RichTextLabel --- scene/gui/rich_text_label.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scene/gui/rich_text_label.cpp b/scene/gui/rich_text_label.cpp index 100c06955a7..6c2928c65c2 100644 --- a/scene/gui/rich_text_label.cpp +++ b/scene/gui/rich_text_label.cpp @@ -935,6 +935,14 @@ void RichTextLabel::_notification(int p_what) { switch (p_what) { + case NOTIFICATION_MOUSE_EXIT: { + if (meta_hovering) { + meta_hovering = NULL; + emit_signal("meta_hover_ended", current_meta); + current_meta = false; + update(); + } + } break; case NOTIFICATION_RESIZED: { main->first_invalid_line = 0; //invalidate ALL