aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Makefile.am2
-rw-r--r--src/datetime-interface.c46
-rw-r--r--src/datetime-interface.h33
3 files changed, 81 insertions, 0 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 8bfac3d..aadc182 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -2,6 +2,8 @@
libexec_PROGRAMS = indicator-datetime-service
indicator_datetime_service_SOURCES = \
+ datetime-interface.c \
+ datetime-interface.h \
datetime-server.h \
datetime-service.c \
dbus-shared.h
diff --git a/src/datetime-interface.c b/src/datetime-interface.c
new file mode 100644
index 0000000..3ea5106
--- /dev/null
+++ b/src/datetime-interface.c
@@ -0,0 +1,46 @@
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include "datetime-interface.h"
+
+static void datetime_interface_class_init (DatetimeInterfaceClass *klass);
+static void datetime_interface_init (DatetimeInterface *self);
+static void datetime_interface_dispose (GObject *object);
+static void datetime_interface_finalize (GObject *object);
+
+G_DEFINE_TYPE (DatetimeInterface, datetime_interface, G_TYPE_OBJECT);
+
+static void
+datetime_interface_class_init (DatetimeInterfaceClass *klass)
+{
+ GObjectClass *object_class = G_OBJECT_CLASS (klass);
+
+ object_class->dispose = datetime_interface_dispose;
+ object_class->finalize = datetime_interface_finalize;
+
+ return;
+}
+
+static void
+datetime_interface_init (DatetimeInterface *self)
+{
+
+ return;
+}
+
+static void
+datetime_interface_dispose (GObject *object)
+{
+
+ G_OBJECT_CLASS (datetime_interface_parent_class)->dispose (object);
+ return;
+}
+
+static void
+datetime_interface_finalize (GObject *object)
+{
+
+ G_OBJECT_CLASS (datetime_interface_parent_class)->finalize (object);
+ return;
+}
diff --git a/src/datetime-interface.h b/src/datetime-interface.h
new file mode 100644
index 0000000..f7ddcf1
--- /dev/null
+++ b/src/datetime-interface.h
@@ -0,0 +1,33 @@
+#ifndef __DATETIME_INTERFACE_H__
+#define __DATETIME_INTERFACE_H__
+
+#include <glib.h>
+#include <glib-object.h>
+
+G_BEGIN_DECLS
+
+#define DATETIME_INTERFACE_TYPE (datetime_interface_get_type ())
+#define DATETIME_INTERFACE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DATETIME_INTERFACE_TYPE, DatetimeInterface))
+#define DATETIME_INTERFACE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DATETIME_INTERFACE_TYPE, DatetimeInterfaceClass))
+#define IS_DATETIME_INTERFACE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DATETIME_INTERFACE_TYPE))
+#define IS_DATETIME_INTERFACE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DATETIME_INTERFACE_TYPE))
+#define DATETIME_INTERFACE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DATETIME_INTERFACE_TYPE, DatetimeInterfaceClass))
+
+typedef struct _DatetimeInterface DatetimeInterface;
+typedef struct _DatetimeInterfaceClass DatetimeInterfaceClass;
+
+struct _DatetimeInterfaceClass {
+ GObjectClass parent_class;
+
+ void (*update_time) (void);
+};
+
+struct _DatetimeInterface {
+ GObject parent;
+};
+
+GType datetime_interface_get_type (void);
+
+G_END_DECLS
+
+#endif