summaryrefslogtreecommitdiff
path: root/plugins/sound/msd-sound-manager.c
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2019-08-18 03:53:17 +0200
committerVictor Kareh <[email protected]>2019-08-20 09:01:31 -0400
commit066d3e77338ac913f86cd6146dce4aec8c7e4de2 (patch)
treee15ea6745d7297804653beee1e9b89df78440b12 /plugins/sound/msd-sound-manager.c
parentc940296930015ce9e247bf7c5bbcc6d8bcc57968 (diff)
downloadmate-settings-daemon-066d3e77338ac913f86cd6146dce4aec8c7e4de2.tar.bz2
mate-settings-daemon-066d3e77338ac913f86cd6146dce4aec8c7e4de2.tar.xz
msd-sound-manager: avoid 'g_type_class_add_private'
Diffstat (limited to 'plugins/sound/msd-sound-manager.c')
-rw-r--r--plugins/sound/msd-sound-manager.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/plugins/sound/msd-sound-manager.c b/plugins/sound/msd-sound-manager.c
index 498d0ff..38dcced 100644
--- a/plugins/sound/msd-sound-manager.c
+++ b/plugins/sound/msd-sound-manager.c
@@ -43,8 +43,6 @@
#include "msd-sound-manager.h"
#include "mate-settings-profile.h"
-#define MSD_SOUND_MANAGER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), MSD_TYPE_SOUND_MANAGER, MsdSoundManagerPrivate))
-
struct MsdSoundManagerPrivate
{
GSettings *settings;
@@ -58,7 +56,7 @@ static void msd_sound_manager_class_init (MsdSoundManagerClass *klass);
static void msd_sound_manager_init (MsdSoundManager *sound_manager);
static void msd_sound_manager_finalize (GObject *object);
-G_DEFINE_TYPE (MsdSoundManager, msd_sound_manager, G_TYPE_OBJECT)
+G_DEFINE_TYPE_WITH_PRIVATE (MsdSoundManager, msd_sound_manager, G_TYPE_OBJECT)
static gpointer manager_object = NULL;
@@ -348,14 +346,12 @@ msd_sound_manager_class_init (MsdSoundManagerClass *klass)
object_class->dispose = msd_sound_manager_dispose;
object_class->finalize = msd_sound_manager_finalize;
-
- g_type_class_add_private (klass, sizeof (MsdSoundManagerPrivate));
}
static void
msd_sound_manager_init (MsdSoundManager *manager)
{
- manager->priv = MSD_SOUND_MANAGER_GET_PRIVATE (manager);
+ manager->priv = msd_sound_manager_get_instance_private (manager);
}
static void