[gtk-doc/win-no-msys: 3/8] tests/gobject/src/*.h: Decorate test APIs
- From: Chun-wei Fan <fanchunwei src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk-doc/win-no-msys: 3/8] tests/gobject/src/*.h: Decorate test APIs
- Date: Wed, 15 Apr 2020 04:05:18 +0000 (UTC)
commit f454ef2c8ec1e7de58e1da8dd5b56fb39c917886
Author: Chun-wei Fan <fanchunwei src gnome org>
Date: Tue Apr 14 12:09:08 2020 +0800
tests/gobject/src/*.h: Decorate test APIs
With this, we can define the decoration macros so that we can export symbols
using compiler directives, such as __declspec(dllexport) for Visual Studio-
style builds.
tests/gobject/src/giface.h | 8 ++++++++
tests/gobject/src/gobject.h | 17 +++++++++++++++++
tests/gobject/src/gtypes.h | 10 ++++++++++
3 files changed, 35 insertions(+)
---
diff --git a/tests/gobject/src/giface.h b/tests/gobject/src/giface.h
index 2883407..a0f96ca 100644
--- a/tests/gobject/src/giface.h
+++ b/tests/gobject/src/giface.h
@@ -4,6 +4,10 @@
#include <glib.h>
#include <glib-object.h>
+#ifndef GTK_DOC_TEST_API
+#define GTK_DOC_TEST_API
+#endif
+
/* type macros */
#define GTKDOC_TYPE_IFACE (gtkdoc_iface_get_type ())
@@ -44,9 +48,13 @@ struct _GtkdocIfaceInterface {
void (*test)(const GtkdocIface * const self, gconstpointer const user_data);
};
+GTK_DOC_TEST_API
GType gtkdoc_iface_get_type(void) G_GNUC_CONST;
+
+GTK_DOC_TEST_API
GType gtkdoc_iface2_get_type(void) G_GNUC_CONST;
+GTK_DOC_TEST_API
gboolean gtkdoc_iface_configure (gchar *config);
/**
diff --git a/tests/gobject/src/gobject.h b/tests/gobject/src/gobject.h
index 03f4262..c9ffdf9 100644
--- a/tests/gobject/src/gobject.h
+++ b/tests/gobject/src/gobject.h
@@ -4,6 +4,10 @@
#include <glib.h>
#include <glib-object.h>
+#ifndef GTK_DOC_TEST_API
+#define GTK_DOC_TEST_API
+#endif
+
/* type macros */
#define GTKDOC_TYPE_OBJECT (gtkdoc_object_get_type ())
@@ -117,16 +121,29 @@ enum GtkdocHelperEnum {
GTKDOC_HELPER_ENUM_B
};
+GTK_DOC_TEST_API
GType gtkdoc_object_get_type(void) G_GNUC_CONST;
+
+GTK_DOC_TEST_API
GType gtkdoc_object2_get_type(void) G_GNUC_CONST;
+
+GTK_DOC_TEST_API
GType gtkdoc_object3_get_type(void) G_GNUC_CONST;
+
+GTK_DOC_TEST_API
GtkdocObject *gtkdoc_object_new(void);
#ifndef GTKDOC_TESTER_DISABLE_DEPRECATED
+GTK_DOC_TEST_API
void gtkdoc_object_set_otest (GObject *self, const gchar *value);
+
+GTK_DOC_TEST_API
void gtkdoc_object_do_not_use (GObject *self);
#endif
+GTK_DOC_TEST_API
void gtkdoc_object_frobnicate (GObject *self, gint n);
+
+GTK_DOC_TEST_API
gboolean gtkdoc_object_fooify (GObject *self, ...);
/**
diff --git a/tests/gobject/src/gtypes.h b/tests/gobject/src/gtypes.h
index 20a7766..c12cd07 100644
--- a/tests/gobject/src/gtypes.h
+++ b/tests/gobject/src/gtypes.h
@@ -4,6 +4,10 @@
#include <glib.h>
#include <glib-object.h>
+#ifndef GTK_DOC_TEST_API
+#define GTK_DOC_TEST_API
+#endif
+
/* type macros */
#define GTKDOC_TYPE_ENUM (gtkdoc_enum_get_type ())
@@ -37,8 +41,13 @@ typedef enum {
GTKDOC_ENUM2_V2,
} GtkdocEnum2;
+GTK_DOC_TEST_API
GType gtkdoc_enum_get_type(void) G_GNUC_CONST;
+
+GTK_DOC_TEST_API
GType gtkdoc_enum2_get_type(void) G_GNUC_CONST;
+
+GTK_DOC_TEST_API
GType gtkdoc_boxed_get_type(void) G_GNUC_CONST;
@@ -72,6 +81,7 @@ typedef struct {
gpointer priv;
} GtkdocBoxedPlainOldData;
+GTK_DOC_TEST_API
GType gtkdoc_boxed_plain_old_data_get_type(void) G_GNUC_CONST;
#endif // GTKDOC_TYPES_H
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]