diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/addressbook/e-book-shell-view-actions.c | 6 | ||||
-rw-r--r-- | modules/addressbook/e-book-shell-view-private.c | 8 | ||||
-rw-r--r-- | modules/calendar/e-cal-shell-content.c | 3 | ||||
-rw-r--r-- | modules/calendar/e-cal-shell-sidebar.c | 7 | ||||
-rw-r--r-- | modules/calendar/e-cal-shell-view-actions.c | 55 | ||||
-rw-r--r-- | modules/calendar/e-cal-shell-view-memopad.c | 6 | ||||
-rw-r--r-- | modules/calendar/e-cal-shell-view-private.c | 3 | ||||
-rw-r--r-- | modules/calendar/e-cal-shell-view-taskpad.c | 6 | ||||
-rw-r--r-- | modules/calendar/e-memo-shell-sidebar.c | 7 | ||||
-rw-r--r-- | modules/calendar/e-task-shell-sidebar.c | 7 | ||||
-rw-r--r-- | modules/calendar/e-task-shell-view-actions.c | 25 | ||||
-rw-r--r-- | modules/calendar/e-task-shell-view-private.c | 3 | ||||
-rw-r--r-- | modules/mail/e-mail-junk-hook.c | 3 |
13 files changed, 101 insertions, 38 deletions
diff --git a/modules/addressbook/e-book-shell-view-actions.c b/modules/addressbook/e-book-shell-view-actions.c index 5cfdbd347d..61434d4e52 100644 --- a/modules/addressbook/e-book-shell-view-actions.c +++ b/modules/addressbook/e-book-shell-view-actions.c @@ -259,7 +259,8 @@ action_address_book_save_as_cb (GtkAction *action, string = eab_suggest_filename (list); file = e_shell_run_save_dialog ( - shell, _("Save as vCard"), string, "*.vcf:text/x-vcard,text/directory", NULL, NULL); + shell, _("Save as vCard"), string, + "*.vcf:text/x-vcard,text/directory", NULL, NULL); g_free (string); if (file == NULL) @@ -522,7 +523,8 @@ action_contact_save_as_cb (GtkAction *action, string = eab_suggest_filename (list); file = e_shell_run_save_dialog ( - shell, _("Save as vCard"), string, "*.vcf:text/x-vcard,text/directory", NULL, NULL); + shell, _("Save as vCard"), string, + "*.vcf:text/x-vcard,text/directory", NULL, NULL); g_free (string); if (file == NULL) diff --git a/modules/addressbook/e-book-shell-view-private.c b/modules/addressbook/e-book-shell-view-private.c index 5b71c3c555..3e2e92a0c0 100644 --- a/modules/addressbook/e-book-shell-view-private.c +++ b/modules/addressbook/e-book-shell-view-private.c @@ -242,8 +242,12 @@ book_shell_view_activate_selected_source (EBookShellView *book_shell_view, widget = e_addressbook_view_new (shell_view, source); gtk_widget_show (widget); - /* default searching options for a new view */ - e_addressbook_view_set_search (E_ADDRESSBOOK_VIEW (widget), CONTACT_FILTER_ANY_CATEGORY, CONTACT_SEARCH_NAME_CONTAINS, NULL, NULL); + /* Default searching options for a new view. */ + e_addressbook_view_set_search ( + E_ADDRESSBOOK_VIEW (widget), + CONTACT_FILTER_ANY_CATEGORY, + CONTACT_SEARCH_NAME_CONTAINS, + NULL, NULL); e_book_shell_content_insert_view ( book_shell_content, diff --git a/modules/calendar/e-cal-shell-content.c b/modules/calendar/e-cal-shell-content.c index 4946972efd..49b2f7f536 100644 --- a/modules/calendar/e-cal-shell-content.c +++ b/modules/calendar/e-cal-shell-content.c @@ -506,7 +506,8 @@ cal_shell_content_constructed (GObject *object) e_table_load_state (E_TABLE (widget), filename); g_free (filename); - e_cal_model_set_default_time_func (e_memo_table_get_model (E_MEMO_TABLE (widget)), gc_get_default_time, calendar); + e_cal_model_set_default_time_func ( + memo_model, gc_get_default_time, calendar); g_signal_connect_swapped ( widget, "open-component", diff --git a/modules/calendar/e-cal-shell-sidebar.c b/modules/calendar/e-cal-shell-sidebar.c index 19c75e3e82..cfe852afed 100644 --- a/modules/calendar/e-cal-shell-sidebar.c +++ b/modules/calendar/e-cal-shell-sidebar.c @@ -529,8 +529,11 @@ cal_shell_sidebar_check_state (EShellSidebar *shell_sidebar) delete = e_source_get_property (source, "delete"); can_delete &= (delete == NULL || strcmp (delete, "no") != 0); - client = g_hash_table_lookup (cal_shell_sidebar->priv->client_table, e_source_peek_uid (source)); - refresh_supported = client && e_cal_get_refresh_supported (client); + client = g_hash_table_lookup ( + cal_shell_sidebar->priv->client_table, + e_source_peek_uid (source)); + refresh_supported = + client && e_cal_get_refresh_supported (client); } if (source != NULL) diff --git a/modules/calendar/e-cal-shell-view-actions.c b/modules/calendar/e-cal-shell-view-actions.c index 117868d646..0e361c5e2c 100644 --- a/modules/calendar/e-cal-shell-view-actions.c +++ b/modules/calendar/e-cal-shell-view-actions.c @@ -170,12 +170,17 @@ action_calendar_jump_to_cb (GtkAction *action, ECalShellView *cal_shell_view) { ECalShellContent *cal_shell_content; + EShellWindow *shell_window; + EShellView *shell_view; GnomeCalendar *calendar; + shell_view = E_SHELL_VIEW (cal_shell_view); + shell_window = e_shell_view_get_shell_window (shell_view); + cal_shell_content = cal_shell_view->priv->cal_shell_content; calendar = e_cal_shell_content_get_calendar (cal_shell_content); - goto_dialog (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (cal_shell_content))), calendar); + goto_dialog (GTK_WINDOW (shell_window), calendar); } static void @@ -350,14 +355,22 @@ static void action_calendar_refresh_cb (GtkAction *action, ECalShellView *cal_shell_view) { + ECalShellContent *cal_shell_content; + ECalShellSidebar *cal_shell_sidebar; + ESourceSelector *selector; ECal *client; ECalModel *model; ESource *source; gchar *uri; GError *error = NULL; - model = e_cal_shell_content_get_model (cal_shell_view->priv->cal_shell_content); - source = e_source_selector_peek_primary_selection (e_cal_shell_sidebar_get_selector (cal_shell_view->priv->cal_shell_sidebar)); + cal_shell_content = cal_shell_view->priv->cal_shell_content; + cal_shell_sidebar = cal_shell_view->priv->cal_shell_sidebar; + + model = e_cal_shell_content_get_model (cal_shell_content); + selector = e_cal_shell_sidebar_get_selector (cal_shell_sidebar); + + source = e_source_selector_peek_primary_selection (selector); g_return_if_fail (E_IS_SOURCE (source)); uri = e_source_get_uri (source); @@ -370,7 +383,10 @@ action_calendar_refresh_cb (GtkAction *action, g_return_if_fail (e_cal_get_refresh_supported (client)); if (!e_cal_refresh (client, &error) && error) { - g_warning ("%s: Failed to refresh '%s', %s\n", G_STRFUNC, e_source_peek_name (source), error->message); + g_warning ( + "%s: Failed to refresh '%s', %s\n", + G_STRFUNC, e_source_peek_name (source), + error->message); g_error_free (error); } } @@ -1071,10 +1087,12 @@ action_event_save_as_cb (GtkAction *action, client = event->comp_data->client; icalcomp = event->comp_data->icalcomp; - /* To Translators: Default filename part saving an event to a file when no summary is filed, the '.ics' extension is concatenated to it */ + /* Translators: Default filename part saving an event to a file when + * no summary is filed, the '.ics' extension is concatenated to it. */ string = icalcomp_suggest_filename (icalcomp, _("event")); file = e_shell_run_save_dialog ( - shell, _("Save as iCalendar"), string, "*.ics:text/calendar", NULL, NULL); + shell, _("Save as iCalendar"), string, + "*.ics:text/calendar", NULL, NULL); g_free (string); if (file == NULL) return; @@ -1134,16 +1152,25 @@ edit_event_as (ECalShellView *cal_shell_view, gboolean as_meeting) /* do it on a copy, as user can cancel changes */ icalcomp = icalcomponent_new_clone (icalcomp); - #define remove_all(_kind) \ - while (prop = icalcomponent_get_first_property (icalcomp, _kind), prop != NULL) { \ - icalcomponent_remove_property (icalcomp, prop); \ - icalproperty_free (prop); \ - } + prop = icalcomponent_get_first_property ( + icalcomp, ICAL_ATTENDEE_PROPERTY); + while (prop != NULL) { + icalcomponent_remove_property (icalcomp, prop); + icalproperty_free (prop); + + prop = icalcomponent_get_first_property ( + icalcomp, ICAL_ATTENDEE_PROPERTY); + } - remove_all (ICAL_ATTENDEE_PROPERTY); - remove_all (ICAL_ORGANIZER_PROPERTY); + prop = icalcomponent_get_first_property ( + icalcomp, ICAL_ORGANIZER_PROPERTY); + while (prop != NULL) { + icalcomponent_remove_property (icalcomp, prop); + icalproperty_free (prop); - #undef remove_all + prop = icalcomponent_get_first_property ( + icalcomp, ICAL_ORGANIZER_PROPERTY); + } } e_calendar_view_edit_appointment ( diff --git a/modules/calendar/e-cal-shell-view-memopad.c b/modules/calendar/e-cal-shell-view-memopad.c index a65bf82cdd..e34dac9adb 100644 --- a/modules/calendar/e-cal-shell-view-memopad.c +++ b/modules/calendar/e-cal-shell-view-memopad.c @@ -219,10 +219,12 @@ action_calendar_memopad_save_as_cb (GtkAction *action, comp_data = list->data; g_slist_free (list); - /* To Translators: Default filename part saving a memo to a file when no summary is filed, the '.ics' extension is concatenated to it */ + /* Translators: Default filename part saving a memo to a file when + * no summary is filed, the '.ics' extension is concatenated to it. */ string = icalcomp_suggest_filename (comp_data->icalcomp, _("memo")); file = e_shell_run_save_dialog ( - shell, _("Save as iCalendar"), string, "*.ics:text/calendar", NULL, NULL); + shell, _("Save as iCalendar"), string, + "*.ics:text/calendar", NULL, NULL); g_free (string); if (file == NULL) return; diff --git a/modules/calendar/e-cal-shell-view-private.c b/modules/calendar/e-cal-shell-view-private.c index 46cb825d21..ddf9dd7204 100644 --- a/modules/calendar/e-cal-shell-view-private.c +++ b/modules/calendar/e-cal-shell-view-private.c @@ -868,7 +868,8 @@ e_cal_shell_view_update_sidebar (ECalShellView *cal_shell_view) view_type = gnome_calendar_get_view (calendar); calendar_view = gnome_calendar_get_calendar_view (calendar, view_type); - if (!e_calendar_view_get_visible_time_range (calendar_view, &start_time, &end_time)) { + if (!e_calendar_view_get_visible_time_range ( + calendar_view, &start_time, &end_time)) { e_shell_sidebar_set_secondary_text (shell_sidebar, ""); return; } diff --git a/modules/calendar/e-cal-shell-view-taskpad.c b/modules/calendar/e-cal-shell-view-taskpad.c index f73d5839d1..33b21aeb55 100644 --- a/modules/calendar/e-cal-shell-view-taskpad.c +++ b/modules/calendar/e-cal-shell-view-taskpad.c @@ -287,10 +287,12 @@ action_calendar_taskpad_save_as_cb (GtkAction *action, comp_data = list->data; g_slist_free (list); - /* To Translators: Default filename part saving a task to a file when no summary is filed, the '.ics' extension is concatenated to it */ + /* Translators: Default filename part saving a task to a file when + * no summary is filed, the '.ics' extension is concatenated to it. */ string = icalcomp_suggest_filename (comp_data->icalcomp, _("task")); file = e_shell_run_save_dialog ( - shell, _("Save as iCalendar"), string, "*.ics:text/calendar", NULL, NULL); + shell, _("Save as iCalendar"), string, + "*.ics:text/calendar", NULL, NULL); g_free (string); if (file == NULL) return; diff --git a/modules/calendar/e-memo-shell-sidebar.c b/modules/calendar/e-memo-shell-sidebar.c index fb8ee9b04a..46ff03672a 100644 --- a/modules/calendar/e-memo-shell-sidebar.c +++ b/modules/calendar/e-memo-shell-sidebar.c @@ -474,8 +474,11 @@ memo_shell_sidebar_check_state (EShellSidebar *shell_sidebar) delete = e_source_get_property (source, "delete"); can_delete &= (delete == NULL || strcmp (delete, "no") != 0); - client = g_hash_table_lookup (memo_shell_sidebar->priv->client_table, e_source_peek_uid (source)); - refresh_supported = client && e_cal_get_refresh_supported (client); + client = g_hash_table_lookup ( + memo_shell_sidebar->priv->client_table, + e_source_peek_uid (source)); + refresh_supported = + client && e_cal_get_refresh_supported (client); } if (source != NULL) diff --git a/modules/calendar/e-task-shell-sidebar.c b/modules/calendar/e-task-shell-sidebar.c index 532e8f696b..eb5da18ffd 100644 --- a/modules/calendar/e-task-shell-sidebar.c +++ b/modules/calendar/e-task-shell-sidebar.c @@ -472,8 +472,11 @@ task_shell_sidebar_check_state (EShellSidebar *shell_sidebar) delete = e_source_get_property (source, "delete"); can_delete &= (delete == NULL || strcmp (delete, "no") != 0); - client = g_hash_table_lookup (task_shell_sidebar->priv->client_table, e_source_peek_uid (source)); - refresh_supported = client && e_cal_get_refresh_supported (client); + client = g_hash_table_lookup ( + task_shell_sidebar->priv->client_table, + e_source_peek_uid (source)); + refresh_supported = + client && e_cal_get_refresh_supported (client); } if (source != NULL) diff --git a/modules/calendar/e-task-shell-view-actions.c b/modules/calendar/e-task-shell-view-actions.c index 067bd48370..3d14678f7b 100644 --- a/modules/calendar/e-task-shell-view-actions.c +++ b/modules/calendar/e-task-shell-view-actions.c @@ -282,16 +282,24 @@ action_task_list_properties_cb (GtkAction *action, static void action_task_list_refresh_cb (GtkAction *action, - ETaskShellView *task_shell_view) + ETaskShellView *task_shell_view) { + ETaskShellContent *task_shell_content; + ETaskShellSidebar *task_shell_sidebar; + ESourceSelector *selector; ECal *client; ECalModel *model; ESource *source; gchar *uri; GError *error = NULL; - model = e_task_shell_content_get_task_model (task_shell_view->priv->task_shell_content); - source = e_source_selector_peek_primary_selection (e_task_shell_sidebar_get_selector (task_shell_view->priv->task_shell_sidebar)); + task_shell_content = task_shell_view->priv->task_shell_content; + task_shell_sidebar = task_shell_view->priv->task_shell_sidebar; + + model = e_task_shell_content_get_task_model (task_shell_content); + selector = e_task_shell_sidebar_get_selector (task_shell_sidebar); + + source = e_source_selector_peek_primary_selection (selector); g_return_if_fail (E_IS_SOURCE (source)); uri = e_source_get_uri (source); @@ -304,7 +312,10 @@ action_task_list_refresh_cb (GtkAction *action, g_return_if_fail (e_cal_get_refresh_supported (client)); if (!e_cal_refresh (client, &error) && error) { - g_warning ("%s: Failed to refresh '%s', %s\n", G_STRFUNC, e_source_peek_name (source), error->message); + g_warning ( + "%s: Failed to refresh '%s', %s\n", + G_STRFUNC, e_source_peek_name (source), + error->message); g_error_free (error); } } @@ -608,10 +619,12 @@ action_task_save_as_cb (GtkAction *action, comp_data = list->data; g_slist_free (list); - /* To Translators: Default filename part saving a task to a file when no summary is filed, the '.ics' extension is concatenated to it */ + /* Translators: Default filename part saving a task to a file when + * no summary is filed, the '.ics' extension is concatenated to it */ string = icalcomp_suggest_filename (comp_data->icalcomp, _("task")); file = e_shell_run_save_dialog ( - shell, _("Save as iCalendar"), string, "*.ics:text/calendar", NULL, NULL); + shell, _("Save as iCalendar"), string, + "*.ics:text/calendar", NULL, NULL); g_free (string); if (file == NULL) return; diff --git a/modules/calendar/e-task-shell-view-private.c b/modules/calendar/e-task-shell-view-private.c index 4337f19a79..533a36d3eb 100644 --- a/modules/calendar/e-task-shell-view-private.c +++ b/modules/calendar/e-task-shell-view-private.c @@ -354,7 +354,8 @@ e_task_shell_view_private_constructed (ETaskShellView *task_shell_view) e_task_shell_view_update_search_filter (task_shell_view); e_task_shell_view_update_timezone (task_shell_view); - /* call this when everything is ready, like actions in action groups and such */ + /* Call this when everything is ready, like actions in + * action groups and such. */ task_shell_view_update_timeout_cb (task_shell_view); priv->update_timeout = g_timeout_add_full ( G_PRIORITY_LOW, 60000, (GSourceFunc) diff --git a/modules/mail/e-mail-junk-hook.c b/modules/mail/e-mail-junk-hook.c index bf4a5ccf36..f17290f99d 100644 --- a/modules/mail/e-mail-junk-hook.c +++ b/modules/mail/e-mail-junk-hook.c @@ -85,7 +85,8 @@ mail_junk_hook_get_name (CamelJunkPlugin *junk_plugin) interface = (EMJunkInterface *) junk_plugin; if (!interface->hook->plugin->enabled) { - /* Translators: "None" for a junk hook name, when the junk plugin is not enabled */ + /* Translators: "None" for a junk hook name, + * when the junk plugin is not enabled. */ return C_("mail-junk-hook", "None"); } |