aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook
diff options
context:
space:
mode:
Diffstat (limited to 'addressbook')
-rw-r--r--addressbook/ChangeLog17
-rw-r--r--addressbook/gui/contact-editor/e-contact-editor.c2
-rw-r--r--addressbook/gui/contact-editor/e-contact-save-as.c18
-rw-r--r--addressbook/gui/contact-editor/e-contact-save-as.h6
-rw-r--r--addressbook/gui/contact-list-editor/e-contact-list-editor.c2
5 files changed, 37 insertions, 8 deletions
diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog
index 0720e50db2..0626df7ae8 100644
--- a/addressbook/ChangeLog
+++ b/addressbook/ChangeLog
@@ -1,5 +1,22 @@
2002-06-15 Chris Toshok <toshok@ximian.com>
+ [ fixes bug #26130 ]
+ * gui/contact-editor/e-contact-editor.c (file_save_as_cb): pass
+ ce->app as parent_window.
+
+ * gui/contact-list-editor/e-contact-list-editor.c
+ (file_save_as_cb): same .
+
+ * gui/contact-editor/e-contact-save-as.c (e_contact_list_save_as):
+ if a parent_window is specified, the file selector should be
+ modal/transient for that window.
+ (e_contact_save_as): same.
+
+ * gui/contact-editor/e-contact-save-as.h: track prototype changes
+ (addition of GtkWindow *parent_window to both calls.)
+
+2002-06-15 Chris Toshok <toshok@ximian.com>
+
* backend/pas/pas-backend-ldap.c (pas_backend_ldap_connect): use
ldap_unbind_ext.
(create_card_handler): don't leak the new vcard.
diff --git a/addressbook/gui/contact-editor/e-contact-editor.c b/addressbook/gui/contact-editor/e-contact-editor.c
index cabc1f7986..0e606c1c91 100644
--- a/addressbook/gui/contact-editor/e-contact-editor.c
+++ b/addressbook/gui/contact-editor/e-contact-editor.c
@@ -1043,7 +1043,7 @@ file_save_as_cb (GtkWidget *widget, gpointer data)
e_card_simple_sync_card (ce->simple);
card = ce->card;
- e_contact_save_as(_("Save Contact as VCard"), card);
+ e_contact_save_as(_("Save Contact as VCard"), card, GTK_WINDOW (ce->app));
}
static void
diff --git a/addressbook/gui/contact-editor/e-contact-save-as.c b/addressbook/gui/contact-editor/e-contact-save-as.c
index 78994ea405..f2251ee233 100644
--- a/addressbook/gui/contact-editor/e-contact-save-as.c
+++ b/addressbook/gui/contact-editor/e-contact-save-as.c
@@ -120,7 +120,7 @@ make_safe_filename (const char *prefix, char *name)
}
void
-e_contact_save_as(char *title, ECard *card)
+e_contact_save_as(char *title, ECard *card, GtkWindow *parent_window)
{
GtkFileSelection *filesel;
char *file;
@@ -145,11 +145,18 @@ e_contact_save_as(char *title, ECard *card)
close_it, info);
gtk_signal_connect(GTK_OBJECT(filesel), "delete_event",
delete_it, info);
+
+ if (parent_window) {
+ gtk_window_set_transient_for (GTK_WINDOW (filesel),
+ parent_window);
+ gtk_window_set_modal (GTK_WINDOW (filesel), TRUE);
+ }
+
gtk_widget_show(GTK_WIDGET(filesel));
}
void
-e_contact_list_save_as(char *title, GList *list)
+e_contact_list_save_as(char *title, GList *list, GtkWindow *parent_window)
{
GtkFileSelection *filesel;
SaveAsInfo *info = g_new(SaveAsInfo, 1);
@@ -181,6 +188,13 @@ e_contact_list_save_as(char *title, GList *list)
close_it, info);
gtk_signal_connect(GTK_OBJECT(filesel), "delete_event",
delete_it, info);
+
+ if (parent_window) {
+ gtk_window_set_transient_for (GTK_WINDOW (filesel),
+ parent_window);
+ gtk_window_set_modal (GTK_WINDOW (filesel), TRUE);
+ }
+
gtk_widget_show(GTK_WIDGET(filesel));
}
diff --git a/addressbook/gui/contact-editor/e-contact-save-as.h b/addressbook/gui/contact-editor/e-contact-save-as.h
index b97d25ee3a..66d1e8bad9 100644
--- a/addressbook/gui/contact-editor/e-contact-save-as.h
+++ b/addressbook/gui/contact-editor/e-contact-save-as.h
@@ -29,10 +29,8 @@ extern "C" {
#pragma }
#endif /* __cplusplus */
-void
-e_contact_save_as(gchar *title, ECard *card);
-void
-e_contact_list_save_as(gchar *title, GList *list);
+void e_contact_save_as (gchar *title, ECard *card, GtkWindow *parent_window);
+void e_contact_list_save_as (gchar *title, GList *list, GtkWindow *parent_window);
#ifdef __cplusplus
}
diff --git a/addressbook/gui/contact-list-editor/e-contact-list-editor.c b/addressbook/gui/contact-list-editor/e-contact-list-editor.c
index abb08d30f8..9c7ddb0d25 100644
--- a/addressbook/gui/contact-list-editor/e-contact-list-editor.c
+++ b/addressbook/gui/contact-list-editor/e-contact-list-editor.c
@@ -427,7 +427,7 @@ file_save_as_cb (GtkWidget *widget, gpointer data)
extract_info (cle);
- e_contact_save_as(_("Save List as VCard"), cle->card);
+ e_contact_save_as(_("Save List as VCard"), cle->card, GTK_WINDOW (cle->app));
}
static void