diff --git a/extensions/tab-panel.c b/extensions/tab-panel.c index a358818a..95e7c535 100644 --- a/extensions/tab-panel.c +++ b/extensions/tab-panel.c @@ -462,7 +462,7 @@ tab_panel_browser_remove_tab_cb (MidoriBrowser* browser, { gboolean minimized = katze_object_get_boolean (view, "minimized"); - if (!(GTK_OBJECT_FLAGS (browser) & GTK_IN_DESTRUCTION)) + if (g_object_get_data (G_OBJECT (browser), "midori-browser-destroyed")) tab_panel_remove_view (browser, view, minimized); } @@ -475,7 +475,7 @@ tab_panel_browser_notify_tab_cb (MidoriBrowser* browser, GtkTreeIter iter; GtkWidget* view; - if (GTK_OBJECT_FLAGS (browser) & GTK_IN_DESTRUCTION) + if (g_object_get_data (G_OBJECT (browser), "midori-browser-destroyed")) return; view = midori_browser_get_current_tab (browser); diff --git a/midori/midori-browser.c b/midori/midori-browser.c index 092ef518..de6b7cd9 100644 --- a/midori/midori-browser.c +++ b/midori/midori-browser.c @@ -5196,6 +5196,8 @@ midori_browser_size_allocate_cb (MidoriBrowser* browser, static void midori_browser_destroy_cb (MidoriBrowser* browser) { + g_object_set_data (G_OBJECT (browser), "midori-browser-destroyed", (void*)1); + if (G_UNLIKELY (browser->panel_timeout)) g_source_remove (browser->panel_timeout); if (G_UNLIKELY (browser->alloc_timeout))