diff options
author | Srinivasa Ragavan <sragavan@src.gnome.org> | 2007-05-30 16:17:32 +0800 |
---|---|---|
committer | Srinivasa Ragavan <sragavan@src.gnome.org> | 2007-05-30 16:17:32 +0800 |
commit | ccce22bf07adb8834c65d8a60d2f8af8cbaa28f8 (patch) | |
tree | 6de44760b2627c6ed5b2cde93e47c230102bc6a6 /addressbook/gui | |
parent | 311badddccc932e38a509837b8f0f1e4fa3a8d18 (diff) | |
download | gsoc2013-evolution-ccce22bf07adb8834c65d8a60d2f8af8cbaa28f8.tar gsoc2013-evolution-ccce22bf07adb8834c65d8a60d2f8af8cbaa28f8.tar.gz gsoc2013-evolution-ccce22bf07adb8834c65d8a60d2f8af8cbaa28f8.tar.bz2 gsoc2013-evolution-ccce22bf07adb8834c65d8a60d2f8af8cbaa28f8.tar.lz gsoc2013-evolution-ccce22bf07adb8834c65d8a60d2f8af8cbaa28f8.tar.xz gsoc2013-evolution-ccce22bf07adb8834c65d8a60d2f8af8cbaa28f8.tar.zst gsoc2013-evolution-ccce22bf07adb8834c65d8a60d2f8af8cbaa28f8.zip |
Fix for bug #333858
svn path=/trunk/; revision=33605
Diffstat (limited to 'addressbook/gui')
-rw-r--r-- | addressbook/gui/contact-editor/e-contact-editor.c | 12 | ||||
-rw-r--r-- | addressbook/gui/contact-editor/e-contact-editor.h | 2 |
2 files changed, 12 insertions, 2 deletions
diff --git a/addressbook/gui/contact-editor/e-contact-editor.c b/addressbook/gui/contact-editor/e-contact-editor.c index bc2d34342e..64965e9590 100644 --- a/addressbook/gui/contact-editor/e-contact-editor.c +++ b/addressbook/gui/contact-editor/e-contact-editor.c @@ -2652,7 +2652,8 @@ categories_response (GtkDialog *dialog, int response, EContactEditor *editor) else e_contact_set (editor->contact, E_CONTACT_CATEGORIES, (char *)categories); } - gtk_widget_hide(GTK_WIDGET(dialog)); + gtk_widget_destroy(GTK_WIDGET(dialog)); + editor->categories_dialog = NULL; } static gint @@ -2677,7 +2678,11 @@ categories_clicked (GtkWidget *button, EContactEditor *editor) else if (editor->contact) categories = e_contact_get (editor->contact, E_CONTACT_CATEGORIES); - if (!(dialog = GTK_DIALOG (e_categories_dialog_new (categories)))) { + if (editor->categories_dialog != NULL){ + gtk_window_present (GTK_WINDOW(editor->categories_dialog)); + g_free (categories); + return; + }else if (!(dialog = GTK_DIALOG (e_categories_dialog_new (categories)))) { e_error_run (NULL, "addressbook:edit-categories", NULL); g_free (categories); return; @@ -2692,6 +2697,8 @@ categories_clicked (GtkWidget *button, EContactEditor *editor) gtk_widget_show(GTK_WIDGET(dialog)); g_free (categories); + + editor->categories_dialog = GTK_WIDGET (dialog); } static void @@ -3292,6 +3299,7 @@ e_contact_editor_init (EContactEditor *e_contact_editor) e_contact_editor->image_changed = FALSE; e_contact_editor->in_async_call = FALSE; e_contact_editor->target_editable = TRUE; + e_contact_editor->categories_dialog = NULL; e_contact_editor->load_source_id = 0; e_contact_editor->load_book = NULL; diff --git a/addressbook/gui/contact-editor/e-contact-editor.h b/addressbook/gui/contact-editor/e-contact-editor.h index de1e657622..73472c1d2b 100644 --- a/addressbook/gui/contact-editor/e-contact-editor.h +++ b/addressbook/gui/contact-editor/e-contact-editor.h @@ -101,6 +101,8 @@ struct _EContactEditor /* signal ids for "writable_status" */ int target_editable_id; + + GtkWidget *categories_dialog; }; struct _EContactEditorClass |