diff options
author | Robin Gareus <robin@gareus.org> | 2017-04-17 01:45:25 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2017-04-17 01:45:25 +0200 |
commit | aff92a019d0f27b4ec6fd92ab78ece9172bec9cc (patch) | |
tree | 9c79d87d1d0c0bb42031c1abe41151bb88275308 /libs/canvas/canvas.cc | |
parent | 976e03c15ccc0f2939507a06eea02a8bfb439e57 (diff) |
Stop tooltip timeout when a canvas-widget or item is hidden.
Diffstat (limited to 'libs/canvas/canvas.cc')
-rw-r--r-- | libs/canvas/canvas.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libs/canvas/canvas.cc b/libs/canvas/canvas.cc index eb40f785dd..fb06b06b97 100644 --- a/libs/canvas/canvas.cc +++ b/libs/canvas/canvas.cc @@ -729,6 +729,15 @@ GtkCanvas::deliver_event (GdkEvent* event) return false; } +void +GtkCanvas::item_shown_or_hidden (Item* item) +{ + if (item == current_tooltip_item) { + stop_tooltip_timeout (); + } + Canvas::item_shown_or_hidden (item); +} + /** Called when an item is being destroyed. * @param item Item being destroyed. * @param bounding_box Last known bounding box of the item. @@ -1136,6 +1145,7 @@ GtkCanvas::on_map () void GtkCanvas::on_unmap () { + stop_tooltip_timeout (); Gtk::EventBox::on_unmap(); #ifdef __APPLE__ if (_nsglview) { |