From cda802676e104ebd6c0a270e187cf61c82949fb2 Mon Sep 17 00:00:00 2001 From: eidheim Date: Thu, 17 Dec 2015 08:49:42 +0100 Subject: [PATCH] Work in progress related to #130 --- src/source.cc | 7 +++++++ src/window.cc | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/source.cc b/src/source.cc index d2aba97..c5d8e2d 100644 --- a/src/source.cc +++ b/src/source.cc @@ -451,6 +451,13 @@ void Source::View::set_tooltip_events() { diagnostic_tooltips.hide(); return false; }); + + signal_leave_notify_event().connect([this](GdkEventCrossing*) { + delayed_tooltips_connection.disconnect(); + type_tooltips.hide(); + diagnostic_tooltips.hide(); + return false; + }); } void Source::View::search_occurrences_updated(GtkWidget* widget, GParamSpec* property, gpointer data) { diff --git a/src/window.cc b/src/window.cc index f7fad76..3c4f6bc 100644 --- a/src/window.cc +++ b/src/window.cc @@ -25,7 +25,7 @@ namespace sigc { Window::Window() : compiling(false) { JDEBUG("start"); set_title("juCi++"); - set_events(Gdk::POINTER_MOTION_MASK|Gdk::FOCUS_CHANGE_MASK|Gdk::SCROLL_MASK); + set_events(Gdk::POINTER_MOTION_MASK|Gdk::FOCUS_CHANGE_MASK|Gdk::SCROLL_MASK|Gdk::LEAVE_NOTIFY_MASK); set_menu_actions(); configure(); set_default_size(Config::get().window.default_size.first, Config::get().window.default_size.second);