From 9345135208e277113cc014c355b2360e0689d51b Mon Sep 17 00:00:00 2001 From: Marco Pesenti Gritti Date: Thu, 11 Sep 2003 19:18:56 +0000 Subject: Make sure to remove show_timeout also when the window is still not 2003-09-11 Marco Pesenti Gritti * lib/widgets/ephy-location-entry.c: (ephy_location_entry_autocompletion_hide_alternatives), (insert_text_cb), (ephy_location_entry_autocompletion_window_hidden_cb): Make sure to remove show_timeout also when the window is still not visible. --- ChangeLog | 10 ++++++++++ lib/widgets/ephy-location-entry.c | 21 ++++++++------------- 2 files changed, 18 insertions(+), 13 deletions(-) diff --git a/ChangeLog b/ChangeLog index 4a99b5f19..314a0a91a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2003-09-11 Marco Pesenti Gritti + + * lib/widgets/ephy-location-entry.c: + (ephy_location_entry_autocompletion_hide_alternatives), + (insert_text_cb), + (ephy_location_entry_autocompletion_window_hidden_cb): + + Make sure to remove show_timeout also when + the window is still not visible. + 2003-09-10 Christian Persch * src/ephy-window.c: (ephy_window_set_active_tab): diff --git a/lib/widgets/ephy-location-entry.c b/lib/widgets/ephy-location-entry.c index 3c1c6ce52..0f2fb663b 100644 --- a/lib/widgets/ephy-location-entry.c +++ b/lib/widgets/ephy-location-entry.c @@ -49,7 +49,6 @@ struct _EphyLocationEntryPrivate { EphyAutocompletion *autocompletion; EphyAutocompletionWindow *autocompletion_window; gboolean autocompletion_window_visible; - gint autocompletion_timeout; gint show_alternatives_timeout; gboolean block_set_autocompletion_key; gboolean going_to_site; @@ -386,6 +385,14 @@ ephy_location_entry_autocompletion_hide_alternatives (EphyLocationEntry *w) ephy_autocompletion_window_hide (p->autocompletion_window); p->autocompletion_window_visible = FALSE; } + + p->autocompletion_window_visible = FALSE; + + if (p->show_alternatives_timeout) + { + g_source_remove (p->show_alternatives_timeout); + p->show_alternatives_timeout = 0; + } } static void @@ -462,12 +469,6 @@ insert_text_cb (GtkWidget *editable, if (p->going_to_site) return; - if (p->autocompletion_timeout != 0) - { - g_source_remove (p->autocompletion_timeout); - p->autocompletion_timeout = 0; - } - if (p->show_alternatives_timeout != 0) { g_source_remove (p->show_alternatives_timeout); @@ -711,12 +712,6 @@ ephy_location_entry_autocompletion_window_hidden_cb (EphyAutocompletionWindow *a g_source_remove (p->show_alternatives_timeout); p->show_alternatives_timeout = 0; } - - if (p->autocompletion_timeout) - { - g_source_remove (p->autocompletion_timeout); - p->autocompletion_timeout = 0; - } } void -- cgit