From 81cb1eaee37c4c89e53d5dce6e5ca3b0e5379aac Mon Sep 17 00:00:00 2001 From: Jeffrey Stedfast Date: Thu, 20 Nov 2003 21:34:42 +0000 Subject: Implemented. (mail_component_class_init): Overload the handleURI method. 2003-11-20 Jeffrey Stedfast * mail-component.c (impl_handleURI): Implemented. (mail_component_class_init): Overload the handleURI method. svn path=/trunk/; revision=23464 --- mail/ChangeLog | 5 +++++ mail/mail-component.c | 23 +++++++++++++++-------- 2 files changed, 20 insertions(+), 8 deletions(-) diff --git a/mail/ChangeLog b/mail/ChangeLog index a2c2740954..50d0e92e5d 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,3 +1,8 @@ +2003-11-20 Jeffrey Stedfast + + * mail-component.c (impl_handleURI): Implemented. + (mail_component_class_init): Overload the handleURI method. + 2003-11-20 Jeffrey Stedfast Fixes bug #51012. diff --git a/mail/mail-component.c b/mail/mail-component.c index a9263ea678..c278e6217b 100644 --- a/mail/mail-component.c +++ b/mail/mail-component.c @@ -347,8 +347,7 @@ impl_createControls (PortableServer_Servant servant, static GNOME_Evolution_CreatableItemTypeList * -impl__get_userCreatableItems (PortableServer_Servant servant, - CORBA_Environment *ev) +impl__get_userCreatableItems (PortableServer_Servant servant, CORBA_Environment *ev) { GNOME_Evolution_CreatableItemTypeList *list = GNOME_Evolution_CreatableItemTypeList__alloc (); @@ -378,13 +377,20 @@ impl_requestCreateItem (PortableServer_Servant servant, ex_GNOME_Evolution_Component_UnknownType, NULL); return; } - + em_utils_compose_new_message (); } static void -impl_sendAndReceive (PortableServer_Servant servant, - CORBA_Environment *ev) +impl_handleURI (PortableServer_Servant servant, const CORBA_char *uri, CORBA_Environment *ev) +{ + if (!strncmp (uri, "mailto:", 7)) { + em_utils_compose_new_message_with_mailto (uri); + } +} + +static void +impl_sendAndReceive (PortableServer_Servant servant, CORBA_Environment *ev) { mail_send_receive (); } @@ -397,15 +403,16 @@ mail_component_class_init (MailComponentClass *class) { POA_GNOME_Evolution_Component__epv *epv = &class->epv; GObjectClass *object_class = G_OBJECT_CLASS (class); - + parent_class = g_type_class_peek_parent (class); - + object_class->dispose = impl_dispose; object_class->finalize = impl_finalize; - + epv->createControls = impl_createControls; epv->_get_userCreatableItems = impl__get_userCreatableItems; epv->requestCreateItem = impl_requestCreateItem; + epv->handleURI = impl_handleURI; epv->sendAndReceive = impl_sendAndReceive; } -- cgit