aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/backend/ebook/e-card.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@helixcode.com>2000-03-23 11:39:14 +0800
committerChris Lahey <clahey@src.gnome.org>2000-03-23 11:39:14 +0800
commita8b3463f5a424f5b90249a9da554525798d21aa3 (patch)
tree53f916205e5492080692ec408a43b68c50c7d3c3 /addressbook/backend/ebook/e-card.c
parent1b84e993c0c4791bde30ea19ce35989375d257ed (diff)
downloadgsoc2013-evolution-a8b3463f5a424f5b90249a9da554525798d21aa3.tar
gsoc2013-evolution-a8b3463f5a424f5b90249a9da554525798d21aa3.tar.gz
gsoc2013-evolution-a8b3463f5a424f5b90249a9da554525798d21aa3.tar.bz2
gsoc2013-evolution-a8b3463f5a424f5b90249a9da554525798d21aa3.tar.lz
gsoc2013-evolution-a8b3463f5a424f5b90249a9da554525798d21aa3.tar.xz
gsoc2013-evolution-a8b3463f5a424f5b90249a9da554525798d21aa3.tar.zst
gsoc2013-evolution-a8b3463f5a424f5b90249a9da554525798d21aa3.zip
Added the addressbook/backend directory.
2000-03-22 Christopher James Lahey <clahey@helixcode.com> * addressbook/Makefile.am, configure.in: Added the addressbook/backend directory. * addressbook/backend/Makefile.am: Removed the libversit directory as it's now included in the base evolution directory. * addressbook/backend/ebook/e-card-pairs.h, addressbook/backend/ebook/Makefile.am: Changed the place where libversit is looked for. * addressbook/backend/ebook/e-book-listener.c: Fixed some indentation. * addressbook/backend/ebook/e-card-pairs.h, addressbook/backend/ebook/e-card-types.h: Commented out some code to get this to compile. * addressbook/backend/ebook/e-card.c, addressbook/backend/ebook/e-card.h: Turned this into a GTK+ object. * addressbook/backend/pas/pas.c, addressbook/backend/ebook/test-client.c: Include gnome.h and gnorba.h. * addressbook/backend/idl/addressbook.idl: Include Bonobo.idl instead of bonobo-unknown.idl. * addressbook/backend/pas/pas-backend-file.c, addressbook/backend/pas/pas-book.c, addressbook/contact-editor/test-editor.c, addressbook/contact-editor/e-contact-editor.c, addressbook/printing/e-contact-print.c, addressbook/printing/test-contact-print-style-editor.c, addressbook/printing/test-print.c: Killed some warnings. svn path=/trunk/; revision=2150
Diffstat (limited to 'addressbook/backend/ebook/e-card.c')
-rw-r--r--addressbook/backend/ebook/e-card.c68
1 files changed, 63 insertions, 5 deletions
diff --git a/addressbook/backend/ebook/e-card.c b/addressbook/backend/ebook/e-card.c
index bc5b13deae..0029694d35 100644
--- a/addressbook/backend/ebook/e-card.c
+++ b/addressbook/backend/ebook/e-card.c
@@ -1,3 +1,4 @@
+/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
* Authors:
* Arturo Espinosa (arturo@nuclecu.unam.mx)
@@ -11,17 +12,73 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-#include <glib.h>
+#include <gtk/gtk.h>
-#include "../libversit/vcc.h"
-#include <e-card-pairs.h>
+#include "libversit/vcc.h"
#include <e-card.h>
+#include <e-card-pairs.h>
#define is_a_prop_of(obj,prop) isAPropertyOf (obj,prop)
#define str_val(obj) the_str = (vObjectValueType (obj))? fakeCString (vObjectUStringZValue (obj)) : calloc (1, 1)
#define has(obj,prop) (vo = isAPropertyOf (obj, prop))
-static VObject *card_convert_to_vobject (Card *crd);
+#if 0
+static VObject *card_convert_to_vobject (ECard *crd);
+#endif
+
+/**
+ * e_card_get_type:
+ * @void:
+ *
+ * Registers the &ECard class if necessary, and returns the type ID
+ * associated to it.
+ *
+ * Return value: The type ID of the &ECard class.
+ **/
+GtkType
+e_card_get_type (void)
+{
+ static GtkType card_type = 0;
+
+ if (!card_type) {
+ GtkTypeInfo card_info = {
+ "ECard",
+ sizeof (ECard),
+ sizeof (ECardClass),
+ NULL,
+ NULL,
+#if 0
+ (GtkClassInitFunc) e_card_class_init,
+ (GtkObjectInitFunc) e_card_init,
+#endif
+ NULL, /* reserved_1 */
+ NULL, /* reserved_2 */
+ (GtkClassInitFunc) NULL
+ };
+
+ card_type = gtk_type_unique (gtk_object_get_type (), &card_info);
+ }
+
+ return card_type;
+}
+
+ECard *e_card_new (char *vcard)
+{
+ return E_CARD(gtk_type_new(e_card_get_type()));
+}
+
+char *e_card_get_id (ECard *card)
+{
+ return NULL;
+}
+
+char *e_card_get_vcard (ECard *card)
+{
+ return NULL;
+}
+
+
+#if 0
/*
* ECard lifecycle management and vCard loading/saving.
@@ -198,7 +255,7 @@ e_card_prop_str_empty (void)
}
/* Intended to check asserts. */
-extern int card_check_prop (CardProperty prop)
+extern int card_check_prop (ECardProperty prop)
{
if (((prop.used == FALSE) || (prop.used == TRUE)) &&
((prop.type >= PROP_NONE) && (prop.type <= PROP_LAST)) &&
@@ -1854,3 +1911,4 @@ card_save (Card *crd, FILE *fp)
writeVObject (fp, object);
cleanVObject (object);
}
+#endif