summaryrefslogtreecommitdiff
path: root/libcaja-private/caja-clipboard-monitor.c
diff options
context:
space:
mode:
authorWu Xiaotian <[email protected]>2019-01-26 12:06:01 +0800
committerraveit65 <[email protected]>2019-01-31 12:24:30 +0100
commit9cd63d4532ec29f9ed133e4f6d8ae07b241de416 (patch)
treed8a02f94d7a24b8fd8ad49439ecce5159f0c19f3 /libcaja-private/caja-clipboard-monitor.c
parent419613671dcf6ec55d8dc49f7bbbb9d11c19d54c (diff)
downloadcaja-9cd63d4532ec29f9ed133e4f6d8ae07b241de416.tar.bz2
caja-9cd63d4532ec29f9ed133e4f6d8ae07b241de416.tar.xz
Avoid deprecated g_type_class_add_private under libcaja-private
Changed CajaClipboardMonitor, CajaColumnChooser and CajaDesktopIconFile
Diffstat (limited to 'libcaja-private/caja-clipboard-monitor.c')
-rw-r--r--libcaja-private/caja-clipboard-monitor.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/libcaja-private/caja-clipboard-monitor.c b/libcaja-private/caja-clipboard-monitor.c
index eabb7844..e9507a72 100644
--- a/libcaja-private/caja-clipboard-monitor.c
+++ b/libcaja-private/caja-clipboard-monitor.c
@@ -53,7 +53,7 @@ enum
LAST_SIGNAL
};
-struct CajaClipboardMonitorDetails
+struct _CajaClipboardMonitorPrivate
{
CajaClipboardInfo *info;
};
@@ -61,7 +61,7 @@ struct CajaClipboardMonitorDetails
static guint signals[LAST_SIGNAL] = { 0 };
static GdkAtom copied_files_atom;
-G_DEFINE_TYPE (CajaClipboardMonitor, caja_clipboard_monitor, G_TYPE_OBJECT);
+G_DEFINE_TYPE_WITH_PRIVATE (CajaClipboardMonitor, caja_clipboard_monitor, G_TYPE_OBJECT);
static CajaClipboardMonitor *clipboard_monitor = NULL;
@@ -141,9 +141,7 @@ caja_clipboard_info_free (CajaClipboardInfo *info)
static void
caja_clipboard_monitor_init (CajaClipboardMonitor *monitor)
{
- monitor->details =
- G_TYPE_INSTANCE_GET_PRIVATE (monitor, CAJA_TYPE_CLIPBOARD_MONITOR,
- CajaClipboardMonitorDetails);
+ monitor->details = caja_clipboard_monitor_get_instance_private (monitor);
}
static void
@@ -189,8 +187,6 @@ caja_clipboard_monitor_class_init (CajaClipboardMonitorClass *klass)
g_cclosure_marshal_VOID__POINTER,
G_TYPE_NONE,
1, G_TYPE_POINTER);
-
- g_type_class_add_private (klass, sizeof (CajaClipboardMonitorDetails));
}
void