diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2011-11-21 14:02:26 +0800 |
---|---|---|
committer | Matthew Barnes <mbarnes@redhat.com> | 2011-11-22 13:12:36 +0800 |
commit | 6f3b2df27f1bcd71880879bf8236663b72002086 (patch) | |
tree | 789947ade349bd66494f75d9473a91ed1a07ce47 /mail | |
parent | c668a350283bfe09edbb39303f655ba2b638eae9 (diff) | |
download | gsoc2013-evolution-6f3b2df27f1bcd71880879bf8236663b72002086.tar gsoc2013-evolution-6f3b2df27f1bcd71880879bf8236663b72002086.tar.gz gsoc2013-evolution-6f3b2df27f1bcd71880879bf8236663b72002086.tar.bz2 gsoc2013-evolution-6f3b2df27f1bcd71880879bf8236663b72002086.tar.lz gsoc2013-evolution-6f3b2df27f1bcd71880879bf8236663b72002086.tar.xz gsoc2013-evolution-6f3b2df27f1bcd71880879bf8236663b72002086.tar.zst gsoc2013-evolution-6f3b2df27f1bcd71880879bf8236663b72002086.zip |
Make EMailNotebookView and EMailPanedView extensible.
Since they each implement EMailReader.
Diffstat (limited to 'mail')
-rw-r--r-- | mail/e-mail-notebook-view.c | 6 | ||||
-rw-r--r-- | mail/e-mail-paned-view.c | 18 |
2 files changed, 17 insertions, 7 deletions
diff --git a/mail/e-mail-notebook-view.c b/mail/e-mail-notebook-view.c index e737b88bfe..aa6b373eaa 100644 --- a/mail/e-mail-notebook-view.c +++ b/mail/e-mail-notebook-view.c @@ -75,7 +75,9 @@ static void e_mail_notebook_view_reader_init (EMailReaderInterface *interface); G_DEFINE_TYPE_WITH_CODE ( EMailNotebookView, e_mail_notebook_view, E_TYPE_MAIL_VIEW, G_IMPLEMENT_INTERFACE ( - E_TYPE_MAIL_READER, e_mail_notebook_view_reader_init)) + E_TYPE_MAIL_READER, e_mail_notebook_view_reader_init) + G_IMPLEMENT_INTERFACE ( + E_TYPE_EXTENSIBLE, NULL)) #if HAVE_CLUTTER static void @@ -624,6 +626,8 @@ mail_notebook_view_constructed (GObject *object) priv->book, "switch-page", G_CALLBACK (mnv_page_changed), object); + e_extensible_load_extensions (E_EXTENSIBLE (object)); + /* Chain up to parent's constructed() method. */ G_OBJECT_CLASS (e_mail_notebook_view_parent_class)->constructed (object); } diff --git a/mail/e-mail-paned-view.c b/mail/e-mail-paned-view.c index c9ebb8a050..84e7894fd5 100644 --- a/mail/e-mail-paned-view.c +++ b/mail/e-mail-paned-view.c @@ -86,7 +86,9 @@ static void e_mail_paned_view_reader_init (EMailReaderInterface *interface); G_DEFINE_TYPE_WITH_CODE ( EMailPanedView, e_mail_paned_view, E_TYPE_MAIL_VIEW, G_IMPLEMENT_INTERFACE ( - E_TYPE_MAIL_READER, e_mail_paned_view_reader_init)) + E_TYPE_MAIL_READER, e_mail_paned_view_reader_init) + G_IMPLEMENT_INTERFACE ( + E_TYPE_EXTENSIBLE, NULL)) static void mail_paned_view_save_boolean (EMailView *view, @@ -626,11 +628,13 @@ mail_paned_view_constructed (GObject *object) shell_settings = e_shell_get_shell_settings (shell); /* Make headers collapsable and store state of headers in config file */ - em_format_html_set_headers_collapsable (EM_FORMAT_HTML (priv->formatter), TRUE); - g_object_bind_property (shell_settings, "paned-view-headers-state", - EM_FORMAT_HTML (priv->formatter), "headers-state", - G_BINDING_BIDIRECTIONAL | - G_BINDING_SYNC_CREATE); + em_format_html_set_headers_collapsable ( + EM_FORMAT_HTML (priv->formatter), TRUE); + g_object_bind_property ( + shell_settings, "paned-view-headers-state", + priv->formatter, "headers-state", + G_BINDING_BIDIRECTIONAL | + G_BINDING_SYNC_CREATE); web_view = em_format_html_get_web_view ( EM_FORMAT_HTML (priv->formatter)); @@ -718,6 +722,8 @@ mail_paned_view_constructed (GObject *object) * set_preview_visible() method relies on it. */ e_mail_view_set_preview_visible (view, TRUE); + e_extensible_load_extensions (E_EXTENSIBLE (object)); + /* Chain up to parent's constructed() method. */ G_OBJECT_CLASS (e_mail_paned_view_parent_class)->constructed (object); } |