summaryrefslogtreecommitdiff
path: root/demo/gclue-service-agent.c
diff options
context:
space:
mode:
authorZeeshan Ali <zeenix@collabora.co.uk>2019-01-04 16:47:59 +0100
committerZeeshan Ali <zeenix@collabora.co.uk>2019-01-04 16:47:59 +0100
commit179a8e59989d4452b7e8fde2f24912e3990436de (patch)
treedb0eb2d4c92d3d8fa48b0678224af47bb1321dd8 /demo/gclue-service-agent.c
parentccbcbb79fb1dae57a36059c98775d89f2091b2d5 (diff)
downloadgeoclue-179a8e59989d4452b7e8fde2f24912e3990436de.tar.gz
Drop use of deprecated g_type_class_add_private()
Use the G_ADD_PRIVATE() macro instead. This doesn't fix the issue in geocode-glib but that's not an issue since we plan to drop geocode-glib (#88). Fixes #98.
Diffstat (limited to 'demo/gclue-service-agent.c')
-rw-r--r--demo/gclue-service-agent.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/demo/gclue-service-agent.c b/demo/gclue-service-agent.c
index 6f2e227..1530fd9 100644
--- a/demo/gclue-service-agent.c
+++ b/demo/gclue-service-agent.c
@@ -40,18 +40,19 @@ gclue_service_agent_agent_iface_init (GClueAgentIface *iface);
static void
gclue_service_agent_constructed (GObject *object);
-G_DEFINE_TYPE_WITH_CODE (GClueServiceAgent,
- gclue_service_agent,
- GCLUE_TYPE_AGENT_SKELETON,
- G_IMPLEMENT_INTERFACE (GCLUE_TYPE_AGENT,
- gclue_service_agent_agent_iface_init))
-
struct _GClueServiceAgentPrivate
{
GDBusConnection *connection;
GDBusProxy *manager_proxy;
};
+G_DEFINE_TYPE_WITH_CODE (GClueServiceAgent,
+ gclue_service_agent,
+ GCLUE_TYPE_AGENT_SKELETON,
+ G_IMPLEMENT_INTERFACE (GCLUE_TYPE_AGENT,
+ gclue_service_agent_agent_iface_init)
+ G_ADD_PRIVATE (GClueServiceAgent))
+
enum
{
PROP_0,
@@ -119,8 +120,6 @@ gclue_service_agent_class_init (GClueServiceAgentClass *klass)
object_class->set_property = gclue_service_agent_set_property;
object_class->constructed = gclue_service_agent_constructed;
- g_type_class_add_private (object_class, sizeof (GClueServiceAgentPrivate));
-
gParamSpecs[PROP_CONNECTION] = g_param_spec_object ("connection",
"Connection",
"DBus Connection",