diff options
Diffstat (limited to 'composer/e-composer-name-header.c')
-rw-r--r-- | composer/e-composer-name-header.c | 29 |
1 files changed, 22 insertions, 7 deletions
diff --git a/composer/e-composer-name-header.c b/composer/e-composer-name-header.c index 70a126b1e0..5aab95d776 100644 --- a/composer/e-composer-name-header.c +++ b/composer/e-composer-name-header.c @@ -295,13 +295,33 @@ e_composer_name_header_get_destinations (EComposerNameHeader *header) } void +e_composer_name_header_add_destinations (EComposerNameHeader *header, + EDestination **destinations) +{ + EDestinationStore *store; + ENameSelectorEntry *entry; + gint ii; + + g_return_if_fail (E_IS_COMPOSER_NAME_HEADER (header)); + + entry = E_COMPOSER_NAME_HEADER_GET_ENTRY (header); + store = e_name_selector_entry_peek_destination_store (entry); + + if (destinations == NULL) + return; + + for (ii = 0; destinations[ii] != NULL; ii++) + e_destination_store_append_destination ( + store, destinations[ii]); +} + +void e_composer_name_header_set_destinations (EComposerNameHeader *header, EDestination **destinations) { EDestinationStore *store; ENameSelectorEntry *entry; GList *list, *iter; - gint ii; g_return_if_fail (E_IS_COMPOSER_NAME_HEADER (header)); @@ -314,10 +334,5 @@ e_composer_name_header_set_destinations (EComposerNameHeader *header, e_destination_store_remove_destination (store, iter->data); g_list_free (list); - if (destinations == NULL) - return; - - for (ii = 0; destinations[ii] != NULL; ii++) - e_destination_store_append_destination ( - store, destinations[ii]); + e_composer_name_header_add_destinations (header, destinations); } |