[evolution-data-server/camel-gobject] Adding GObject macros.



commit 26e5873e60fa55dcf856d9dd404c1fff878927a6
Author: Matthew Barnes <mbarnes redhat com>
Date:   Sat Apr 18 11:14:45 2009 -0400

    Adding GObject macros.
---
 camel/providers/nntp/camel-nntp-folder.h        |   34 +++++++++++++++-------
 camel/providers/nntp/camel-nntp-store-summary.h |   26 ++++++++++++++---
 camel/providers/nntp/camel-nntp-stream.h        |   23 +++++++++++++---
 camel/providers/nntp/camel-nntp-summary.h       |   26 ++++++++++++++---
 4 files changed, 84 insertions(+), 25 deletions(-)

diff --git a/camel/providers/nntp/camel-nntp-folder.h b/camel/providers/nntp/camel-nntp-folder.h
index a8d6342..05b9fac 100644
--- a/camel/providers/nntp/camel-nntp-folder.h
+++ b/camel/providers/nntp/camel-nntp-folder.h
@@ -24,17 +24,29 @@
 
 
 #ifndef CAMEL_NNTP_FOLDER_H
-#define CAMEL_NNTP_FOLDER_H 1
-
-#include "camel/camel-folder.h"
-#include "camel/camel-disco-folder.h"
-
-/*  #include "camel-store.h" */
-
-#define CAMEL_NNTP_FOLDER_TYPE     (camel_nntp_folder_get_type ())
-#define CAMEL_NNTP_FOLDER(obj)     (G_TYPE_CHECK_INSTANCE_CAST((obj), CAMEL_NNTP_FOLDER_TYPE, CamelNNTPFolder))
-#define CAMEL_NNTP_FOLDER_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k), CAMEL_NNTP_FOLDER_TYPE, CamelNNTPFolderClass))
-#define CAMEL_IS_NNTP_FOLDER(o)    (G_TYPE_CHECK_INSTANCE_TYPE((o), CAMEL_NNTP_FOLDER_TYPE))
+#define CAMEL_NNTP_FOLDER_H
+
+#include <camel/camel-folder.h>
+#include <camel/camel-disco-folder.h>
+
+/* Standard GObject macros */
+#define CAMEL_TYPE_NNTP_FOLDER \
+	(camel_nntp_folder_get_type ())
+#define CAMEL_NNTP_FOLDER(obj) \
+	(G_TYPE_CHECK_INSTANCE_CAST \
+	((obj), CAMEL_TYPE_NNTP_FOLDER, CamelNNTPFolder))
+#define CAMEL_NNTP_FOLDER_CLASS(cls) \
+	(G_TYPE_CHECK_CLASS_CAST \
+	((cls), CAMEL_TYPE_NNTP_FOLDER, CamelNNTPFolderClass))
+#define CAMEL_IS_NNTP_FOLDER(obj) \
+	(G_TYPE_CHECK_INSTANCE_TYPE \
+	((obj), CAMEL_TYPE_NNTP_FOLDER))
+#define CAMEL_IS_NNTP_FOLDER_CLASS(cls) \
+	(G_TYPE_CHECK_CLASS_TYPE \
+	((cls), CAMEL_TYPE_NNTP_FOLDER))
+#define CAMEL_NNTP_FOLDER_GET_CLASS(obj) \
+	(G_TYPE_INSTANCE_GET_CLASS \
+	((obj), CAMEL_TYPE_NNTP_FOLDER, CamelNNTPFolderClass))
 
 G_BEGIN_DECLS
 
diff --git a/camel/providers/nntp/camel-nntp-store-summary.h b/camel/providers/nntp/camel-nntp-store-summary.h
index 6340087..8f63e95 100644
--- a/camel/providers/nntp/camel-nntp-store-summary.h
+++ b/camel/providers/nntp/camel-nntp-store-summary.h
@@ -28,14 +28,30 @@
 #include <camel/camel-object.h>
 #include <camel/camel-store-summary.h>
 
-#define CAMEL_NNTP_STORE_SUMMARY(obj)         G_TYPE_CHECK_INSTANCE_CAST (obj, camel_nntp_store_summary_get_type (), CamelNNTPStoreSummary)
-#define CAMEL_NNTP_STORE_SUMMARY_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, camel_nntp_store_summary_get_type (), CamelNNTPStoreSummaryClass)
-#define CAMEL_IS_NNTP_STORE_SUMMARY(obj)      G_TYPE_CHECK_INSTANCE_TYPE (obj, camel_nntp_store_summary_get_type ())
+/* Standard GObject macros */
+#define CAMEL_TYPE_NNTP_STORE_SUMMARY \
+	(camel_nntp_store_summary_get_type ())
+#define CAMEL_NNTP_STORE_SUMMARY(obj) \
+	(G_TYPE_CHECK_INSTANCE_CAST \
+	((obj), CAMEL_TYPE_NNTP_STORE_SUMMARY, CamelNNTPStoreSummary))
+#define CAMEL_NNTP_STORE_SUMMARY_CLASS(cls) \
+	(G_TYPE_CHECK_CLASS_CAST \
+	((cls), CAMEL_TYPE_NNTP_STORE_SUMMARY, CamelNNTPStoreSummaryClass))
+#define CAMEL_IS_NNTP_STORE_SUMMARY(obj) \
+	(G_TYPE_CHECK_INSTANCE_TYPE \
+	((obj), CAMEL_TYPE_NNTP_STORE_SUMMARY))
+#define CAMEL_IS_NNTP_STORE_SUMMARY_CLASS(cls) \
+	(G_TYPE_CHECK_CLASS_TYPE \
+	((cls), CAMEL_TYPE_NNTP_STORE_SUMMARY))
+#define CAMEL_NNTP_STORE_SUMMARY_GET_CLASS(obj) \
+	(G_TYPE_INSTANCE_GET_CLASS \
+	((obj), CAMEL_TYPE_NNTP_STORE_SUMMARY, CamelNNTPStoreSummaryClass))
 
 G_BEGIN_DECLS
 
-typedef struct _CamelNNTPStoreSummary      CamelNNTPStoreSummary;
+typedef struct _CamelNNTPStoreSummary CamelNNTPStoreSummary;
 typedef struct _CamelNNTPStoreSummaryClass CamelNNTPStoreSummaryClass;
+typedef struct _CamelNNTPStoreSummaryPrivate CamelNNTPStoreSummaryPrivate;
 
 typedef struct _CamelNNTPStoreInfo CamelNNTPStoreInfo;
 
@@ -56,7 +72,7 @@ struct _CamelNNTPStoreInfo {
 struct _CamelNNTPStoreSummary {
 	CamelStoreSummary summary;
 
-	struct _CamelNNTPStoreSummaryPrivate *priv;
+	CamelNNTPStoreSummaryPrivate *priv;
 
 	/* header info */
 	guint32 version;	/* version of base part of file */
diff --git a/camel/providers/nntp/camel-nntp-stream.h b/camel/providers/nntp/camel-nntp-stream.h
index 8a6b02a..7919d3b 100644
--- a/camel/providers/nntp/camel-nntp-stream.h
+++ b/camel/providers/nntp/camel-nntp-stream.h
@@ -23,14 +23,29 @@
 
 #include <camel/camel-stream.h>
 
-#define CAMEL_NNTP_STREAM(obj)         G_TYPE_CHECK_INSTANCE_CAST (obj, camel_nntp_stream_get_type (), CamelNNTPStream)
-#define CAMEL_NNTP_STREAM_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, camel_nntp_stream_get_type (), CamelNNTPStreamClass)
-#define CAMEL_IS_NNTP_STREAM(obj)      G_TYPE_CHECK_INSTANCE_TYPE (obj, camel_nntp_stream_get_type ())
+/* Standard GObject macros */
+#define CAMEL_TYPE_NNTP_STREAM \
+	(camel_nntp_stream_get_type ())
+#define CAMEL_NNTP_STREAM(obj) \
+	(G_TYPE_CHECK_INSTANCE_CAST \
+	((obj), CAMEL_TYPE_NNTP_STREAM, CamelNNTPStream))
+#define CAMEL_NNTP_STREAM_CLASS(cls) \
+	(G_TYPE_CHECK_CLASS_CAST \
+	((cls), CAMEL_TYPE_NNTP_STREAM, CamelNNTPStreamClass))
+#define CAMEL_IS_NNTP_STREAM(obj) \
+	(G_TYPE_CHECK_INSTANCE_TYPE \
+	((obj), CAMEL_TYPE_NNTP_STREAM))
+#define CAMEL_IS_NNTP_STREAM_CLASS(cls) \
+	(G_TYPE_CHECK_CLASS_TYPE \
+	((cls), CAMEL_TYPE_NNTP_STREAM))
+#define CAMEL_NNTP_STREAM_GET_CLASS(obj) \
+	(G_TYPE_INSTANCE_GET_CLASS \
+	((obj), CAMEL_TYPE_NNTP_STREAM, CamelNNTPStreamClass))
 
 G_BEGIN_DECLS
 
-typedef struct _CamelNNTPStreamClass CamelNNTPStreamClass;
 typedef struct _CamelNNTPStream CamelNNTPStream;
+typedef struct _CamelNNTPStreamClass CamelNNTPStreamClass;
 
 typedef enum {
 	CAMEL_NNTP_STREAM_LINE,
diff --git a/camel/providers/nntp/camel-nntp-summary.h b/camel/providers/nntp/camel-nntp-summary.h
index 11aefe9..f8ca446 100644
--- a/camel/providers/nntp/camel-nntp-summary.h
+++ b/camel/providers/nntp/camel-nntp-summary.h
@@ -23,9 +23,24 @@
 
 #include <camel/camel-folder-summary.h>
 
-#define CAMEL_NNTP_SUMMARY(obj)         G_TYPE_CHECK_INSTANCE_CAST (obj, camel_nntp_summary_get_type (), CamelNNTPSummary)
-#define CAMEL_NNTP_SUMMARY_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, camel_nntp_summary_get_type (), CamelNNTPSummaryClass)
-#define CAMEL_IS_LOCAL_SUMMARY(obj)      G_TYPE_CHECK_INSTANCE_TYPE (obj, camel_nntp_summary_get_type ())
+/* Standard GObject macros */
+#define CAMEL_TYPE_NNTP_SUMMARY \
+	(camel_nntp_summary_get_type ())
+#define CAMEL_NNTP_SUMMARY(obj) \
+	(G_TYPE_CHECK_INSTANCE_CAST \
+	((obj), CAMEL_TYPE_NNTP_SUMMARY, CamelNNTPSummary))
+#define CAMEL_NNTP_SUMMARY_CLASS(cls) \
+	(G_TYPE_CHECK_CLASS_CAST \
+	((cls), CAMEL_TYPE_NNTP_SUMMARY, CamelNNTPSummaryClass))
+#define CAMEL_IS_NNTP_SUMMARY(obj) \
+	(G_TYPE_CHECK_INSTANCE_TYPE \
+	((obj), CAMEL_TYPE_NNTP_SUMMARY))
+#define CAMEL_IS_NNTP_SUMMARY_CLASS(cls) \
+	(G_TYPE_CHECK_CLASS_TYPE \
+	((cls), CAMEL_TYPE_NNTP_SUMMARY))
+#define CAMEL_NNTP_SUMMARY_GET_CLASS(obj) \
+	(G_TYPE_INSTANCE_GET_CLASS \
+	((obj), CAMEL_TYPE_NNTP_SUMMARY, CamelNNTPSummaryClass))
 
 G_BEGIN_DECLS
 
@@ -33,13 +48,14 @@ struct _CamelNNTPStore;
 struct _CamelFolderChangeInfo;
 struct _CamelException;
 
-typedef struct _CamelNNTPSummary      CamelNNTPSummary;
+typedef struct _CamelNNTPSummary CamelNNTPSummary;
 typedef struct _CamelNNTPSummaryClass CamelNNTPSummaryClass;
+typedef struct _CamelNNTPSummaryPrivate CamelNNTPSummaryPrivate;
 
 struct _CamelNNTPSummary {
 	CamelFolderSummary parent;
 
-	struct _CamelNNTPSummaryPrivate *priv;
+	CamelNNTPSummaryPrivate *priv;
 
 	guint32 version;
 	guint32 high, low;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]