diff options
author | Ettore Perazzoli <ettore@src.gnome.org> | 2003-11-13 21:38:24 +0800 |
---|---|---|
committer | Ettore Perazzoli <ettore@src.gnome.org> | 2003-11-13 21:38:24 +0800 |
commit | 23ff4e713bb247cb093e469ea53c61d1950035dc (patch) | |
tree | 2bc4f984e1ea39c1745edf57b5f97c433db14780 | |
parent | d4213cf4e40424ddd54f41b6f5534b5f19a8c260 (diff) | |
download | gsoc2013-evolution-23ff4e713bb247cb093e469ea53c61d1950035dc.tar gsoc2013-evolution-23ff4e713bb247cb093e469ea53c61d1950035dc.tar.gz gsoc2013-evolution-23ff4e713bb247cb093e469ea53c61d1950035dc.tar.bz2 gsoc2013-evolution-23ff4e713bb247cb093e469ea53c61d1950035dc.tar.lz gsoc2013-evolution-23ff4e713bb247cb093e469ea53c61d1950035dc.tar.xz gsoc2013-evolution-23ff4e713bb247cb093e469ea53c61d1950035dc.tar.zst gsoc2013-evolution-23ff4e713bb247cb093e469ea53c61d1950035dc.zip |
(impl__get_userCreatableItems): New, implementation for the
userCreatableItems property.
(impl_requestCreateItem): New, implementation for the
requestCreateItem method.
(addressbook_component_class_init): Install.
svn path=/trunk/; revision=23325
-rw-r--r-- | addressbook/ChangeLog | 9 | ||||
-rw-r--r-- | addressbook/gui/component/addressbook-component.c | 43 |
2 files changed, 51 insertions, 1 deletions
diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog index 3a8a3512d3..a3e6abef1d 100644 --- a/addressbook/ChangeLog +++ b/addressbook/ChangeLog @@ -1,3 +1,12 @@ +2003-11-13 Ettore Perazzoli <ettore@ximian.com> + + * gui/component/addressbook-component.c + (impl__get_userCreatableItems): New, implementation for the + userCreatableItems property. + (impl_requestCreateItem): New, implementation for the + requestCreateItem method. + (addressbook_component_class_init): Install. + 2003-11-12 Ettore Perazzoli <ettore@ximian.com> * gui/component/GNOME_Evolution_Addressbook.server.in.in: Add diff --git a/addressbook/gui/component/addressbook-component.c b/addressbook/gui/component/addressbook-component.c index 7f0ca913ed..7de8d85022 100644 --- a/addressbook/gui/component/addressbook-component.c +++ b/addressbook/gui/component/addressbook-component.c @@ -163,6 +163,45 @@ impl_createControls (PortableServer_Servant servant, *corba_view_control = CORBA_Object_duplicate (BONOBO_OBJREF (view_control), ev); } +static GNOME_Evolution_CreatableItemTypeList * +impl__get_userCreatableItems (PortableServer_Servant servant, + CORBA_Environment *ev) +{ + GNOME_Evolution_CreatableItemTypeList *list = GNOME_Evolution_CreatableItemTypeList__alloc (); + + list->_length = 2; + list->_maximum = list->_length; + list->_buffer = GNOME_Evolution_CreatableItemTypeList_allocbuf (list->_length); + + CORBA_sequence_set_release (list, FALSE); + + list->_buffer[0].id = "contact"; + list->_buffer[0].description = _("New Contact"); + list->_buffer[0].menuDescription = _("_Contact"); + list->_buffer[0].tooltip = _("Create a new contact"); + list->_buffer[0].menuShortcut = 'c'; + list->_buffer[0].iconName = "evolution-contacts-mini.png"; + + list->_buffer[1].id = "contact_list"; + list->_buffer[1].description = _("New Contact List"); + list->_buffer[1].menuDescription = _("Contact _List"); + list->_buffer[1].tooltip = _("Create a new contact list"); + list->_buffer[1].menuShortcut = 'l'; + list->_buffer[1].iconName = "contact-list-16.png"; + + return list; +} + +static void +impl_requestCreateItem (PortableServer_Servant servant, + const CORBA_char *item_type_name, + CORBA_Environment *ev) +{ + /* FIXME: fill me in */ + + CORBA_exception_set (ev, CORBA_USER_EXCEPTION, ex_GNOME_Evolution_Component_UnknownType, NULL); +} + /* GObject methods. */ @@ -203,7 +242,9 @@ addressbook_component_class_init (AddressbookComponentClass *class) POA_GNOME_Evolution_Component__epv *epv = &class->epv; GObjectClass *object_class = G_OBJECT_CLASS (class); - epv->createControls = impl_createControls; + epv->createControls = impl_createControls; + epv->_get_userCreatableItems = impl__get_userCreatableItems; + epv->requestCreateItem = impl_requestCreateItem; object_class->dispose = impl_dispose; object_class->finalize = impl_finalize; |