From: Sergio Villar SenĂ­n Date: Mon, 4 May 2009 10:43:38 +0000 (+0200) Subject: Fixes NB#112215, set "select contacts" and "message settings" dialogs to application... X-Git-Tag: 3.0.16-rc1~7 X-Git-Url: http://git.maemo.org/git/?p=modest;a=commitdiff_plain;h=4cded6641b87db71547140e9c68020ff9ec126d6 Fixes NB#112215, set "select contacts" and "message settings" dialogs to application modal instead of system modal --- diff --git a/src/gnome/modest-address-book.c b/src/gnome/modest-address-book.c index eaf4e02..4a006d9 100644 --- a/src/gnome/modest-address-book.c +++ b/src/gnome/modest-address-book.c @@ -38,7 +38,8 @@ modest_address_book_add_address (const gchar *address) } void -modest_address_book_select_addresses (ModestRecptEditor *editor) +modest_address_book_select_addresses (ModestRecptEditor *editor, + GtkWindow *parent_window) { g_message (__FUNCTION__); } diff --git a/src/hildon2/modest-address-book.c b/src/hildon2/modest-address-book.c index aaf6413..31e6e9e 100644 --- a/src/hildon2/modest-address-book.c +++ b/src/hildon2/modest-address-book.c @@ -226,7 +226,8 @@ modest_address_book_add_address (const gchar *address) } void -modest_address_book_select_addresses (ModestRecptEditor *recpt_editor) +modest_address_book_select_addresses (ModestRecptEditor *recpt_editor, + GtkWindow *parent_window) { #if MODEST_ABOOK_API < 4 GtkWidget *contact_view = NULL; @@ -269,7 +270,7 @@ modest_address_book_select_addresses (ModestRecptEditor *recpt_editor) } #else /* MODEST_ABOOK_API < 4 */ /* TODO: figure out how to make the contact chooser modal */ - contact_chooser = osso_abook_contact_chooser_new_with_capabilities (NULL, + contact_chooser = osso_abook_contact_chooser_new_with_capabilities (parent_window, _AB("addr_ti_dia_select_contacts"), OSSO_ABOOK_CAPS_EMAIL, OSSO_ABOOK_CONTACT_ORDER_NAME); diff --git a/src/hildon2/modest-msg-edit-window.c b/src/hildon2/modest-msg-edit-window.c index 496cef8..69f2706 100644 --- a/src/hildon2/modest-msg-edit-window.c +++ b/src/hildon2/modest-msg-edit-window.c @@ -2923,8 +2923,7 @@ modest_msg_edit_window_open_addressbook (ModestMsgEditWindow *window, } - modest_address_book_select_addresses (editor); - + modest_address_book_select_addresses (editor, GTK_WINDOW (window)); } void @@ -4185,6 +4184,9 @@ modest_msg_edit_window_show_msg_settings_dialog (ModestMsgEditWindow *window) g_signal_connect (G_OBJECT (html_toggle), "toggled", G_CALLBACK (on_format_toggle), &helper); g_signal_connect (G_OBJECT (text_toggle), "toggled", G_CALLBACK (on_format_toggle), &helper); + modest_window_mgr_set_modal (modest_runtime_get_window_mgr (), + GTK_WINDOW (dialog), GTK_WINDOW (window)); + /* Save settings if the user clicked on done */ if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_ACCEPT) { TnyHeaderFlags flags; diff --git a/src/maemo/modest-address-book.c b/src/maemo/modest-address-book.c index faa1fb1..8dee6d6 100644 --- a/src/maemo/modest-address-book.c +++ b/src/maemo/modest-address-book.c @@ -169,7 +169,8 @@ modest_address_book_add_address (const gchar *address) } void -modest_address_book_select_addresses (ModestRecptEditor *recpt_editor) +modest_address_book_select_addresses (ModestRecptEditor *recpt_editor, + GtkWindow *parent_window) { #if MODEST_ABOOK_API < 4 GtkWidget *contact_view = NULL; diff --git a/src/maemo/modest-msg-edit-window.c b/src/maemo/modest-msg-edit-window.c index 9fd2947..89da6dd 100644 --- a/src/maemo/modest-msg-edit-window.c +++ b/src/maemo/modest-msg-edit-window.c @@ -2717,7 +2717,7 @@ modest_msg_edit_window_open_addressbook (ModestMsgEditWindow *window, } - modest_address_book_select_addresses (editor); + modest_address_book_select_addresses (editor, GTK_WINDOW (window)); } diff --git a/src/modest-address-book-dummy.c b/src/modest-address-book-dummy.c index ab11940..1e90c6f 100644 --- a/src/modest-address-book-dummy.c +++ b/src/modest-address-book-dummy.c @@ -41,7 +41,8 @@ void modest_address_book_add_address (const gchar *address) } -void modest_address_book_select_addresses (ModestRecptEditor *editor) +void modest_address_book_select_addresses (ModestRecptEditor *editor, + GtkWindow *parent_window); { return; } diff --git a/src/modest-address-book.h b/src/modest-address-book.h index 418b323..084a0f4 100644 --- a/src/modest-address-book.h +++ b/src/modest-address-book.h @@ -52,7 +52,8 @@ modest_address_book_add_address (const gchar *address); * */ void -modest_address_book_select_addresses (ModestRecptEditor *editor); +modest_address_book_select_addresses (ModestRecptEditor *editor, + GtkWindow *parent_window); /** * modest_address_book_check_names: