diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2013-06-02 23:48:46 +0800 |
---|---|---|
committer | Matthew Barnes <mbarnes@redhat.com> | 2013-06-03 04:14:46 +0800 |
commit | 2d3fbbaa9205a6ed6f65650bb99e91d9aac00908 (patch) | |
tree | 792a67d699fe41ec2955b1cf8f2cebf0e9661c4f | |
parent | 2d2d30c05b8f54de94a89be3db54df024a11fc7e (diff) | |
download | gsoc2013-evolution-2d3fbbaa9205a6ed6f65650bb99e91d9aac00908.tar gsoc2013-evolution-2d3fbbaa9205a6ed6f65650bb99e91d9aac00908.tar.gz gsoc2013-evolution-2d3fbbaa9205a6ed6f65650bb99e91d9aac00908.tar.bz2 gsoc2013-evolution-2d3fbbaa9205a6ed6f65650bb99e91d9aac00908.tar.lz gsoc2013-evolution-2d3fbbaa9205a6ed6f65650bb99e91d9aac00908.tar.xz gsoc2013-evolution-2d3fbbaa9205a6ed6f65650bb99e91d9aac00908.tar.zst gsoc2013-evolution-2d3fbbaa9205a6ed6f65650bb99e91d9aac00908.zip |
em_utils_compose_new_message(): Return the EMsgComposer.
(cherry picked from commit 1b7fc9224b7107361282904483805c67d4980586)
-rw-r--r-- | mail/em-composer-utils.c | 10 | ||||
-rw-r--r-- | mail/em-composer-utils.h | 2 |
2 files changed, 8 insertions, 4 deletions
diff --git a/mail/em-composer-utils.c b/mail/em-composer-utils.c index 686b493333..b941e06d1b 100644 --- a/mail/em-composer-utils.c +++ b/mail/em-composer-utils.c @@ -1087,22 +1087,26 @@ create_new_composer (EShell *shell, * * Opens a new composer window as a child window of @parent's toplevel * window. + * + * Returns: the resulting #EMsgComposer **/ -void +EMsgComposer * em_utils_compose_new_message (EShell *shell, CamelFolder *folder) { EMsgComposer *composer; - g_return_if_fail (E_IS_SHELL (shell)); + g_return_val_if_fail (E_IS_SHELL (shell), NULL); if (folder != NULL) - g_return_if_fail (CAMEL_IS_FOLDER (folder)); + g_return_val_if_fail (CAMEL_IS_FOLDER (folder), NULL); composer = create_new_composer (shell, "", folder); composer_set_no_change (composer); gtk_widget_show (GTK_WIDGET (composer)); + + return composer; } /** diff --git a/mail/em-composer-utils.h b/mail/em-composer-utils.h index fff33624e2..719bc5b6bd 100644 --- a/mail/em-composer-utils.h +++ b/mail/em-composer-utils.h @@ -32,7 +32,7 @@ G_BEGIN_DECLS -void em_utils_compose_new_message (EShell *shell, +EMsgComposer * em_utils_compose_new_message (EShell *shell, CamelFolder *folder); EMsgComposer * em_utils_compose_new_message_with_mailto (EShell *shell, |