From 1a875361956a7dcbbbae00e43f6e582a42c01bb7 Mon Sep 17 00:00:00 2001 From: Armin Burgmeier Date: Sat, 2 Jun 2007 19:34:33 +0000 Subject: [PATCH] 2007-06-02 Armin Burgmeier * src/maemo/modest-account-settings-dialog.c: Changed window title to include account type and account title. This fixes projects.maemo.org bug NB#59000. pmo-trunk-r2048 --- ChangeLog2 | 8 ++++++++ src/maemo/modest-account-settings-dialog.c | 19 +++++++++++++++---- src/maemo/modest-account-view-window.c | 2 ++ 3 files changed, 25 insertions(+), 4 deletions(-) diff --git a/ChangeLog2 b/ChangeLog2 index 774dd5a..ac55d97 100644 --- a/ChangeLog2 +++ b/ChangeLog2 @@ -1,5 +1,13 @@ 2007-06-02 Armin Burgmeier + * src/maemo/modest-account-settings-dialog.c: Changed window title to + include account type and account title. This fixes projects.maemo.org + bug NB#59000. + + * src/maemo/modest-account-view-window.c: Set a title for the window. + +2007-06-02 Armin Burgmeier + * src/maemo/easysetup/modest-easysetup-wizard.c: Always prefill incoming and outgoing server name based on email address and server types as long as the names have not been edited manually. This fixes diff --git a/src/maemo/modest-account-settings-dialog.c b/src/maemo/modest-account-settings-dialog.c index 4baf0a8..50d747b 100644 --- a/src/maemo/modest-account-settings-dialog.c +++ b/src/maemo/modest-account-settings-dialog.c @@ -908,9 +908,6 @@ modest_account_settings_dialog_init (ModestAccountSettingsDialog *self) * Each page of the notebook will be a page of the wizard: */ GtkNotebook *notebook = GTK_NOTEBOOK (gtk_notebook_new()); - - gtk_window_set_title (GTK_WINDOW (self), _("mcen_ti_emailsetup")); - /* Get the account manager object, * so we can check for existing accounts, * and create new accounts: */ @@ -1138,7 +1135,21 @@ void modest_account_settings_dialog_set_account_name (ModestAccountSettingsDialo GTK_TOGGLE_BUTTON (dialog->checkbox_outgoing_smtp_specific), has_specific); } - + + /* Set window title according to account: */ + /* TODO: Is this the correct way to find a human-readable name for + * the protocol used? */ + const gchar* proto_str = modest_protocol_info_get_transport_store_protocol_name (dialog->incoming_protocol); + gchar *proto_name = g_utf8_strup(proto_str, -1); + gchar *account_title = modest_account_mgr_get_display_name(dialog->account_manager, account_name); + + gchar *title = g_strdup_printf(_("mcen_ti_account_settings"), proto_name, account_title); + g_free (proto_name); + g_free (account_title); + + gtk_window_set_title (GTK_WINDOW (dialog), title); + g_free (title); + /* account_data->is_enabled, */ /*account_data->is_default, */ diff --git a/src/maemo/modest-account-view-window.c b/src/maemo/modest-account-view-window.c index 9eeca58..feb65ea 100644 --- a/src/maemo/modest-account-view-window.c +++ b/src/maemo/modest-account-view-window.c @@ -384,6 +384,8 @@ modest_account_view_window_init (ModestAccountViewWindow *obj) gtk_box_pack_start (GTK_BOX((GTK_DIALOG (obj)->action_area)), GTK_WIDGET (button_box_new (obj)), TRUE, TRUE, 2); + + gtk_window_set_title (GTK_WINDOW (obj), _("mcen_ti_emailsetup_accounts")); } -- 1.7.9.5