Branch data Line data Source code
1 : : /*
2 : : SPDX-License-Identifier: GPL-2.0-or-later AND LGPL-2.0-or-later AND MIT
3 : : SPDX-FileCopyrightText: 2008 Johan Dahlin
4 : : SPDX-FileCopyrightText: 2009 Andreas Rottmann <a.rottmann@gmx.at>
5 : : */
6 : :
7 : : #include "utility.h"
8 : :
9 [ + + + - : 18 : G_DEFINE_TYPE (UtilityObject, utility_object, G_TYPE_OBJECT);
+ + ]
10 : :
11 : : /**
12 : : * UtilityBuffer:
13 : : * @data: (type gpointer): the data
14 : : *
15 : : **/
16 : :
17 : : static void
18 : 2 : utility_object_finalize (GObject *gobj)
19 : : {
20 : 2 : UtilityObject *self = UTILITY_OBJECT(gobj);
21 [ + + ]: 2 : if (self->destroy_notify)
22 : 1 : self->destroy_notify(self->user_data);
23 : 2 : G_OBJECT_CLASS(utility_object_parent_class)->finalize(gobj);
24 : 2 : }
25 : :
26 : : static void
27 : 3 : utility_object_class_init (UtilityObjectClass *klass G_GNUC_UNUSED)
28 : : {
29 : 3 : G_OBJECT_CLASS(klass)->finalize = utility_object_finalize;
30 : 3 : }
31 : :
32 : : static void
33 : 2 : utility_object_init (UtilityObject *object G_GNUC_UNUSED)
34 : : {
35 : 2 : }
36 : :
37 : : /**
38 : : * utility_object_watch_dir:
39 : : * @object:
40 : : * @path:
41 : : * @func: (destroy destroy):
42 : : * @user_data:
43 : : * @destroy:
44 : : */
45 : : void
46 : 1 : utility_object_watch_dir (UtilityObject *object,
47 : : const char *path G_GNUC_UNUSED,
48 : : UtilityFileFunc func G_GNUC_UNUSED,
49 : : gpointer user_data,
50 : : GDestroyNotify destroy)
51 : : {
52 : 1 : object->user_data = user_data;
53 : 1 : object->destroy_notify = destroy;
54 : 1 : }
55 : :
56 : : /**
57 : : * utility_dir_foreach:
58 : : * @path:
59 : : * @func: (scope call):
60 : : * @user_data:
61 : : *
62 : : */
63 : : void
64 : 1 : utility_dir_foreach (const char *path G_GNUC_UNUSED,
65 : : UtilityFileFunc func G_GNUC_UNUSED,
66 : : gpointer user_data G_GNUC_UNUSED)
67 : : {
68 : 1 : }
|