]> git.0d.be Git - empathy.git/commitdiff
Only destroy block confirmation dialogs after we've read out the abusive state
authorDanielle Madeley <danielle.madeley@collabora.co.uk>
Mon, 14 Feb 2011 01:36:22 +0000 (12:36 +1100)
committerChandni Verma <chandniverma2112@gmail.com>
Fri, 11 Mar 2011 05:10:23 +0000 (10:40 +0530)
libempathy-gtk/empathy-contact-dialogs.c
libempathy-gtk/empathy-individual-dialogs.c

index 737a449d2eb49220a1f3535c329227749792d78d..06481cf7d1b5f507d3d88af33cc82b3df4019383 100644 (file)
@@ -556,8 +556,6 @@ empathy_block_contact_dialog_show (GtkWindow      *parent,
        }
 
        res = gtk_dialog_run (GTK_DIALOG (dialog));
-       gtk_widget_destroy (dialog);
-
        if (abusive != NULL) {
                if (abusive_check != NULL) {
                        *abusive = gtk_toggle_button_get_active (
@@ -567,6 +565,7 @@ empathy_block_contact_dialog_show (GtkWindow      *parent,
                }
        }
 
+       gtk_widget_destroy (dialog);
        g_object_unref (manager);
 
        return res == GTK_RESPONSE_REJECT;
index 1d3fcb8e2849e20f69ad8450ad17ad0815f1d9b1..e141182ba224c29599aba2ee604710bd4071a691 100644 (file)
@@ -240,7 +240,6 @@ empathy_block_individual_dialog_show (GtkWindow *parent,
   g_string_free (str, TRUE);
 
   res = gtk_dialog_run (GTK_DIALOG (dialog));
-  gtk_widget_destroy (dialog);
 
   if (abusive != NULL)
     {
@@ -251,5 +250,7 @@ empathy_block_individual_dialog_show (GtkWindow *parent,
         *abusive = FALSE;
     }
 
+  gtk_widget_destroy (dialog);
+
   return res == GTK_RESPONSE_REJECT;
 }