From e551b43db8b8342ec39df544921c39f2e377d5bf Mon Sep 17 00:00:00 2001 From: Christian Persch Date: Wed, 23 Jun 2004 20:10:49 +0000 Subject: Use g_signal_connect_after to connect to the toolbar_added signal, 2004-06-23 Christian Persch * src/bookmarks/ephy-bookmarksbar.c: (ephy_bookmarksbar_set_window): * src/toolbar.c: (toolbar_realize): Use g_signal_connect_after to connect to the toolbar_added signal, otherwise the toolbar isn't created yet and we crash when trying to set the drag dests on a newly added toolbar. --- src/bookmarks/ephy-bookmarksbar.c | 4 ++-- src/toolbar.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/bookmarks/ephy-bookmarksbar.c b/src/bookmarks/ephy-bookmarksbar.c index 1d666c0c4..3855090cc 100644 --- a/src/bookmarks/ephy-bookmarksbar.c +++ b/src/bookmarks/ephy-bookmarksbar.c @@ -297,8 +297,8 @@ ephy_bookmarksbar_set_window (EphyBookmarksBar *toolbar, "ToolbarsModel", model, NULL); - g_signal_connect (model, "toolbar_added", - G_CALLBACK (toolbar_added_cb), toolbar); + g_signal_connect_after (model, "toolbar_added", + G_CALLBACK (toolbar_added_cb), toolbar); /* now that the toolbar has been constructed, set drag dests */ n_toolbars = egg_toolbars_model_n_toolbars (model); diff --git a/src/toolbar.c b/src/toolbar.c index cf6596f32..16981fb02 100755 --- a/src/toolbar.c +++ b/src/toolbar.c @@ -207,8 +207,8 @@ toolbar_realize (GtkWidget *widget) GTK_WIDGET_CLASS (parent_class)->realize (widget); - g_signal_connect (model, "toolbar_added", - G_CALLBACK (toolbar_added_cb), toolbar); + g_signal_connect_after (model, "toolbar_added", + G_CALLBACK (toolbar_added_cb), toolbar); /* now that the toolbar has been constructed, set drag dests */ n_toolbars = egg_toolbars_model_n_toolbars (model); -- cgit