diff options
Diffstat (limited to 'src/bookmarks/ephy-new-bookmark.c')
-rw-r--r-- | src/bookmarks/ephy-new-bookmark.c | 22 |
1 files changed, 4 insertions, 18 deletions
diff --git a/src/bookmarks/ephy-new-bookmark.c b/src/bookmarks/ephy-new-bookmark.c index db69e4ee7..332e737bd 100644 --- a/src/bookmarks/ephy-new-bookmark.c +++ b/src/bookmarks/ephy-new-bookmark.c @@ -185,10 +185,12 @@ response_cb (EphyNewBookmark *new_bookmark, "epiphany", "to-create-new-bookmark"); break; - case GTK_RESPONSE_CANCEL: - break; + /* For both OK and Cancel we want to destroy the dialog */ case GTK_RESPONSE_OK: ephy_new_bookmark_add (new_bookmark); + case GTK_RESPONSE_CANCEL: + default: + gtk_widget_destroy (GTK_WIDGET (new_bookmark)); break; } } @@ -465,19 +467,3 @@ ephy_new_bookmark_get_id (EphyNewBookmark *bookmark) { return bookmark->priv->id; } - -/* Convenience function for callers */ - -void -ephy_new_bookmark_response_cb (EphyNewBookmark *bookmark, - int response_id, - gpointer user_data) -{ - switch (response_id) - { - case GTK_RESPONSE_CANCEL: - case GTK_RESPONSE_OK: - gtk_widget_destroy (GTK_WIDGET (bookmark)); - break; - } -} |