summaryrefslogtreecommitdiff
path: root/plugins/housekeeping/msd-housekeeping-manager.c
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2019-08-17 14:57:29 +0200
committerVictor Kareh <[email protected]>2019-08-20 09:01:31 -0400
commit1cb5ea510bb4f21b44c23982ae869242f3fb4767 (patch)
tree65106b74b837500258aa9e0ccb3d746930ab525d /plugins/housekeeping/msd-housekeeping-manager.c
parent5ddc646f7850861fd8a3e4ab6c4c7adeb6e1b0ca (diff)
downloadmate-settings-daemon-1cb5ea510bb4f21b44c23982ae869242f3fb4767.tar.bz2
mate-settings-daemon-1cb5ea510bb4f21b44c23982ae869242f3fb4767.tar.xz
msd-housekeeping-manager: avoid 'g_type_class_add_private'
Diffstat (limited to 'plugins/housekeeping/msd-housekeeping-manager.c')
-rw-r--r--plugins/housekeeping/msd-housekeeping-manager.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/plugins/housekeeping/msd-housekeeping-manager.c b/plugins/housekeeping/msd-housekeeping-manager.c
index e04f527..43d615f 100644
--- a/plugins/housekeeping/msd-housekeeping-manager.c
+++ b/plugins/housekeeping/msd-housekeeping-manager.c
@@ -44,12 +44,10 @@ struct MsdHousekeepingManagerPrivate {
GSettings *settings;
};
-#define MSD_HOUSEKEEPING_MANAGER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), MSD_TYPE_HOUSEKEEPING_MANAGER, MsdHousekeepingManagerPrivate))
-
static void msd_housekeeping_manager_class_init (MsdHousekeepingManagerClass *klass);
static void msd_housekeeping_manager_init (MsdHousekeepingManager *housekeeping_manager);
-G_DEFINE_TYPE (MsdHousekeepingManager, msd_housekeeping_manager, G_TYPE_OBJECT)
+G_DEFINE_TYPE_WITH_PRIVATE (MsdHousekeepingManager, msd_housekeeping_manager, G_TYPE_OBJECT)
static gpointer manager_object = NULL;
@@ -302,13 +300,12 @@ msd_housekeeping_manager_stop (MsdHousekeepingManager *manager)
static void
msd_housekeeping_manager_class_init (MsdHousekeepingManagerClass *klass)
{
- g_type_class_add_private (klass, sizeof (MsdHousekeepingManagerPrivate));
}
static void
msd_housekeeping_manager_init (MsdHousekeepingManager *manager)
{
- manager->priv = MSD_HOUSEKEEPING_MANAGER_GET_PRIVATE (manager);
+ manager->priv = msd_housekeeping_manager_get_instance_private (manager);
}
MsdHousekeepingManager *