@img/sharp-libvips-dev-wasm32 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/include/aom/aom_encoder.h +3 -3
- package/include/aom/aomcx.h +17 -8
- package/include/glib-2.0/gio/gappinfo.h +0 -7
- package/include/glib-2.0/gio/gapplicationcommandline.h +12 -1
- package/include/glib-2.0/gio/gasyncinitable.h +0 -7
- package/include/glib-2.0/gio/gasyncresult.h +0 -6
- package/include/glib-2.0/gio/gbufferedinputstream.h +0 -5
- package/include/glib-2.0/gio/gbufferedoutputstream.h +0 -5
- package/include/glib-2.0/gio/gbytesicon.h +0 -5
- package/include/glib-2.0/gio/gcancellable.h +0 -5
- package/include/glib-2.0/gio/gconverter.h +0 -7
- package/include/glib-2.0/gio/gconverterinputstream.h +0 -6
- package/include/glib-2.0/gio/gconverteroutputstream.h +0 -6
- package/include/glib-2.0/gio/gdatagrambased.h +0 -7
- package/include/glib-2.0/gio/gdatainputstream.h +0 -6
- package/include/glib-2.0/gio/gdataoutputstream.h +0 -6
- package/include/glib-2.0/gio/gdbusinterface.h +0 -8
- package/include/glib-2.0/gio/gdbusinterfaceskeleton.h +0 -8
- package/include/glib-2.0/gio/gdbusmessage.h +2 -1
- package/include/glib-2.0/gio/gdbusobjectmanagerclient.h +0 -8
- package/include/glib-2.0/gio/gdbusobjectmanagerserver.h +0 -8
- package/include/glib-2.0/gio/gdbusobjectproxy.h +0 -8
- package/include/glib-2.0/gio/gdbusobjectskeleton.h +0 -8
- package/include/glib-2.0/gio/gdbusproxy.h +0 -8
- package/include/glib-2.0/gio/gdebugcontroller.h +0 -8
- package/include/glib-2.0/gio/gdebugcontrollerdbus.h +0 -7
- package/include/glib-2.0/gio/gdtlsserverconnection.h +0 -8
- package/include/glib-2.0/gio/gemblem.h +0 -5
- package/include/glib-2.0/gio/gemblemedicon.h +0 -5
- package/include/glib-2.0/gio/gfile.h +0 -10
- package/include/glib-2.0/gio/gfileenumerator.h +0 -5
- package/include/glib-2.0/gio/gfileicon.h +0 -5
- package/include/glib-2.0/gio/gfileinfo.h +0 -5
- package/include/glib-2.0/gio/gfileinputstream.h +0 -8
- package/include/glib-2.0/gio/gfileiostream.h +0 -8
- package/include/glib-2.0/gio/gfilemonitor.h +0 -5
- package/include/glib-2.0/gio/gfilenamecompleter.h +0 -5
- package/include/glib-2.0/gio/gfileoutputstream.h +0 -8
- package/include/glib-2.0/gio/gfilterinputstream.h +0 -5
- package/include/glib-2.0/gio/gfilteroutputstream.h +0 -5
- package/include/glib-2.0/gio/gicon.h +0 -5
- package/include/glib-2.0/gio/ginitable.h +0 -7
- package/include/glib-2.0/gio/ginputstream.h +0 -5
- package/include/glib-2.0/gio/gio-autocleanups.h +4 -0
- package/include/glib-2.0/gio/gio-visibility.h +34 -0
- package/include/glib-2.0/gio/gioenums.h +6 -1
- package/include/glib-2.0/gio/giomodule.h +0 -5
- package/include/glib-2.0/gio/giostream.h +0 -5
- package/include/glib-2.0/gio/giotypes.h +5 -107
- package/include/glib-2.0/gio/gloadableicon.h +0 -6
- package/include/glib-2.0/gio/gmemoryinputstream.h +0 -5
- package/include/glib-2.0/gio/gmemoryoutputstream.h +0 -5
- package/include/glib-2.0/gio/gmountoperation.h +0 -6
- package/include/glib-2.0/gio/gnetworking.h +4 -0
- package/include/glib-2.0/gio/goutputstream.h +0 -9
- package/include/glib-2.0/gio/gpollableinputstream.h +0 -7
- package/include/glib-2.0/gio/gpollableoutputstream.h +0 -7
- package/include/glib-2.0/gio/gproxy.h +0 -7
- package/include/glib-2.0/gio/gproxyaddressenumerator.h +0 -8
- package/include/glib-2.0/gio/gseekable.h +0 -5
- package/include/glib-2.0/gio/gsettingsbackend.h +0 -5
- package/include/glib-2.0/gio/gsimpleactiongroup.h +0 -7
- package/include/glib-2.0/gio/gsimpleasyncresult.h +0 -5
- package/include/glib-2.0/gio/gsimpleproxyresolver.h +0 -5
- package/include/glib-2.0/gio/gsocket.h +13 -0
- package/include/glib-2.0/gio/gsocketaddressenumerator.h +0 -6
- package/include/glib-2.0/gio/gsocketconnectable.h +0 -5
- package/include/glib-2.0/gio/gtask.h +12 -0
- package/include/glib-2.0/gio/gthemedicon.h +0 -5
- package/include/glib-2.0/gio/gtlsserverconnection.h +0 -8
- package/include/glib-2.0/gio/gunixcredentialsmessage.h +0 -8
- package/include/glib-2.0/gio/gvfs.h +0 -5
- package/include/glib-2.0/gio/gvolume.h +2 -2
- package/include/glib-2.0/gio/gvolumemonitor.h +0 -5
- package/include/glib-2.0/glib/deprecated/gcompletion.h +1 -1
- package/include/glib-2.0/glib/deprecated/grel.h +0 -23
- package/include/glib-2.0/glib/deprecated/gthread.h +1 -1
- package/include/glib-2.0/glib/gatomic.h +20 -20
- package/include/glib-2.0/glib/gbookmarkfile.h +39 -1
- package/include/glib-2.0/glib/gchecksum.h +0 -10
- package/include/glib-2.0/glib/gdate.h +0 -9
- package/include/glib-2.0/glib/gdatetime.h +33 -1
- package/include/glib-2.0/glib/gdir.h +5 -0
- package/include/glib-2.0/glib/ghmac.h +0 -9
- package/include/glib-2.0/glib/glib-autocleanups.h +4 -0
- package/include/glib-2.0/glib/glib-visibility.h +34 -0
- package/include/glib-2.0/glib/gmacros.h +1 -0
- package/include/glib-2.0/glib/gmessages.h +3 -0
- package/include/glib-2.0/glib/gpathbuf.h +0 -7
- package/include/glib-2.0/glib/gstdio.h +1 -1
- package/include/glib-2.0/glib/gstrvbuilder.h +4 -8
- package/include/glib-2.0/glib/gtestutils.h +5 -0
- package/include/glib-2.0/glib/gthread.h +25 -0
- package/include/glib-2.0/glib/gunicode.h +12 -2
- package/include/glib-2.0/glib/gvarianttype.h +1 -10
- package/include/glib-2.0/glib/gversionmacros.h +9 -0
- package/include/glib-2.0/glib/gwin32.h +4 -4
- package/include/glib-2.0/glib-unix.h +208 -0
- package/include/glib-2.0/gmodule/gmodule-visibility.h +34 -0
- package/include/glib-2.0/gobject/gbinding.h +0 -8
- package/include/glib-2.0/gobject/gbindinggroup.h +0 -8
- package/include/glib-2.0/gobject/gclosure.h +1 -9
- package/include/glib-2.0/gobject/glib-types.h +33 -0
- package/include/glib-2.0/gobject/gobject-autocleanups.h +4 -0
- package/include/glib-2.0/gobject/gobject-visibility.h +34 -0
- package/include/glib-2.0/gobject/gobject.h +1 -16
- package/include/glib-2.0/gobject/gparam.h +3 -12
- package/include/glib-2.0/gobject/gsignal.h +1 -1
- package/include/glib-2.0/gobject/gsignalgroup.h +0 -8
- package/include/glib-2.0/gobject/gtype.h +53 -20
- package/include/glib-2.0/gobject/gtypemodule.h +0 -7
- package/include/glib-2.0/gobject/gtypeplugin.h +0 -6
- package/include/glib-2.0/gobject/gvaluearray.h +0 -7
- package/include/glib-2.0/gobject/gvaluecollector.h +1 -11
- package/include/glib-2.0/gobject/gvaluetypes.h +2 -0
- package/include/lcms2.h +46 -7
- package/include/lcms2_plugin.h +4 -4
- package/include/libheif/heif_version.h +2 -2
- package/include/resvg.h +2 -2
- package/include/vips/version.h +4 -4
- package/include/zlib.h +3 -3
- package/lib/glib-2.0/include/glibconfig.h +2 -2
- package/lib/libaom.a +0 -0
- package/lib/libcgif.a +0 -0
- package/lib/libexif.a +0 -0
- package/lib/libexpat.a +0 -0
- package/lib/libffi.a +0 -0
- package/lib/libgio-2.0.a +0 -0
- package/lib/libglib-2.0.a +0 -0
- package/lib/libgmodule-2.0.a +0 -0
- package/lib/libgobject-2.0.a +0 -0
- package/lib/libgthread-2.0.a +0 -0
- package/lib/libheif.a +0 -0
- package/lib/libhwy.a +0 -0
- package/lib/libimagequant.a +0 -0
- package/lib/libjpeg.a +0 -0
- package/lib/liblcms2.a +0 -0
- package/lib/libresvg.a +0 -0
- package/lib/libsharpyuv.a +0 -0
- package/lib/libspng.a +0 -0
- package/lib/libtiff.a +0 -0
- package/lib/libvips-cpp.a +0 -0
- package/lib/libvips.a +0 -0
- package/lib/libwebp.a +0 -0
- package/lib/libwebpdemux.a +0 -0
- package/lib/libwebpmux.a +0 -0
- package/lib/libz.a +0 -0
- package/lib/pkgconfig/aom.pc +2 -2
- package/lib/pkgconfig/gio-2.0.pc +3 -3
- package/lib/pkgconfig/glib-2.0.pc +3 -3
- package/lib/pkgconfig/gmodule-2.0.pc +1 -1
- package/lib/pkgconfig/gmodule-export-2.0.pc +1 -1
- package/lib/pkgconfig/gmodule-no-export-2.0.pc +1 -1
- package/lib/pkgconfig/gobject-2.0.pc +1 -1
- package/lib/pkgconfig/gthread-2.0.pc +1 -1
- package/lib/pkgconfig/lcms2.pc +1 -1
- package/lib/pkgconfig/libheif.pc +1 -1
- package/lib/pkgconfig/vips-cpp.pc +1 -1
- package/lib/pkgconfig/vips.pc +1 -1
- package/lib/pkgconfig/zlib.pc +1 -1
- package/package.json +1 -1
- package/versions.json +8 -7
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
|
|
34
34
|
#include <glib/gtypes.h>
|
|
35
35
|
|
|
36
|
-
#
|
|
36
|
+
#if defined(G_PLATFORM_WIN32) || defined(__GI_SCANNER__)
|
|
37
37
|
|
|
38
38
|
G_BEGIN_DECLS
|
|
39
39
|
|
|
@@ -41,7 +41,7 @@ G_BEGIN_DECLS
|
|
|
41
41
|
#define MAXPATHLEN 1024
|
|
42
42
|
#endif
|
|
43
43
|
|
|
44
|
-
#
|
|
44
|
+
#if defined(G_OS_WIN32) || defined(__GI_SCANNER__)
|
|
45
45
|
|
|
46
46
|
/*
|
|
47
47
|
* To get prototypes for the following POSIXish functions, you have to
|
|
@@ -68,7 +68,7 @@ G_BEGIN_DECLS
|
|
|
68
68
|
GLIB_AVAILABLE_IN_ALL
|
|
69
69
|
gint g_win32_ftruncate (gint f,
|
|
70
70
|
guint size);
|
|
71
|
-
#endif /* G_OS_WIN32 */
|
|
71
|
+
#endif /* G_OS_WIN32 || __GI_SCANNER__ */
|
|
72
72
|
|
|
73
73
|
/* The MS setlocale uses locale names of the form "English_United
|
|
74
74
|
* States.1252" etc. We want the Unixish standard form "en", "zh_TW"
|
|
@@ -137,6 +137,6 @@ gboolean g_win32_check_windows_version (const gint major,
|
|
|
137
137
|
|
|
138
138
|
G_END_DECLS
|
|
139
139
|
|
|
140
|
-
#endif /* G_PLATFORM_WIN32 */
|
|
140
|
+
#endif /* G_PLATFORM_WIN32 || __GI_SCANNER__ */
|
|
141
141
|
|
|
142
142
|
#endif /* __G_WIN32_H__ */
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/* glib-unix.h - Unix specific integration
|
|
2
2
|
* Copyright (C) 2011 Red Hat, Inc.
|
|
3
|
+
* Copyright 2023 Collabora Ltd.
|
|
3
4
|
*
|
|
4
5
|
* SPDX-License-Identifier: LGPL-2.1-or-later
|
|
5
6
|
*
|
|
@@ -33,6 +34,7 @@
|
|
|
33
34
|
#include <fcntl.h>
|
|
34
35
|
|
|
35
36
|
#include <glib.h>
|
|
37
|
+
#include <glib/gstdio.h>
|
|
36
38
|
|
|
37
39
|
#ifndef G_OS_UNIX
|
|
38
40
|
#error "This header may only be used on UNIX"
|
|
@@ -120,6 +122,212 @@ GLIB_AVAILABLE_IN_2_64
|
|
|
120
122
|
struct passwd *g_unix_get_passwd_entry (const gchar *user_name,
|
|
121
123
|
GError **error);
|
|
122
124
|
|
|
125
|
+
/**
|
|
126
|
+
* GUnixPipe:
|
|
127
|
+
* @fds: A pair of file descriptors, each negative if closed or not yet opened.
|
|
128
|
+
* The file descriptor with index %G_UNIX_PIPE_END_READ is readable.
|
|
129
|
+
* The file descriptor with index %G_UNIX_PIPE_END_WRITE is writable.
|
|
130
|
+
*
|
|
131
|
+
* A Unix pipe. The advantage of this type over `int[2]` is that it can
|
|
132
|
+
* be closed automatically when it goes out of scope, using `g_auto(GUnixPipe)`,
|
|
133
|
+
* on compilers that support that feature.
|
|
134
|
+
*
|
|
135
|
+
* Since: 2.80
|
|
136
|
+
*/
|
|
137
|
+
GLIB_AVAILABLE_TYPE_IN_2_80
|
|
138
|
+
typedef struct {
|
|
139
|
+
int fds[2];
|
|
140
|
+
} GUnixPipe;
|
|
141
|
+
|
|
142
|
+
/**
|
|
143
|
+
* GUnixPipeEnd:
|
|
144
|
+
* @G_UNIX_PIPE_END_READ: The readable file descriptor 0
|
|
145
|
+
* @G_UNIX_PIPE_END_WRITE: The writable file descriptor 1
|
|
146
|
+
*
|
|
147
|
+
* Mnemonic constants for the ends of a Unix pipe.
|
|
148
|
+
*
|
|
149
|
+
* Since: 2.80
|
|
150
|
+
*/
|
|
151
|
+
GLIB_AVAILABLE_TYPE_IN_2_80
|
|
152
|
+
typedef enum
|
|
153
|
+
{
|
|
154
|
+
G_UNIX_PIPE_END_READ = 0,
|
|
155
|
+
G_UNIX_PIPE_END_WRITE = 1
|
|
156
|
+
} GUnixPipeEnd;
|
|
157
|
+
|
|
158
|
+
/**
|
|
159
|
+
* G_UNIX_PIPE_INIT:
|
|
160
|
+
*
|
|
161
|
+
* Initializer for a #GUnixPipe that has not yet been opened.
|
|
162
|
+
* Both of its file descriptors are initialized to `-1` (invalid),
|
|
163
|
+
* the same as if they had been closed.
|
|
164
|
+
*
|
|
165
|
+
* Since: 2.80
|
|
166
|
+
*/
|
|
167
|
+
#define G_UNIX_PIPE_INIT { { -1, -1 } } GLIB_AVAILABLE_MACRO_IN_2_80
|
|
168
|
+
|
|
169
|
+
/* Suppress "Not available before" warnings when declaring the
|
|
170
|
+
* implementations */
|
|
171
|
+
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
|
|
172
|
+
|
|
173
|
+
/**
|
|
174
|
+
* g_unix_pipe_open:
|
|
175
|
+
* @self: A pair of file descriptors
|
|
176
|
+
* @flags: Flags to pass to g_unix_open_pipe(), typically `FD_CLOEXEC`
|
|
177
|
+
* @error: Used to report an error on failure
|
|
178
|
+
*
|
|
179
|
+
* Open a pipe. This is the same as g_unix_open_pipe(), but uses the
|
|
180
|
+
* #GUnixPipe data structure.
|
|
181
|
+
*
|
|
182
|
+
* Returns: %TRUE on success
|
|
183
|
+
*
|
|
184
|
+
* Since: 2.80
|
|
185
|
+
*/
|
|
186
|
+
GLIB_AVAILABLE_STATIC_INLINE_IN_2_80
|
|
187
|
+
static inline gboolean
|
|
188
|
+
g_unix_pipe_open (GUnixPipe *self,
|
|
189
|
+
int flags,
|
|
190
|
+
GError **error)
|
|
191
|
+
{
|
|
192
|
+
return g_unix_open_pipe (self->fds, flags, error);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
/**
|
|
196
|
+
* g_unix_pipe_get:
|
|
197
|
+
* @self: A pair of file descriptors
|
|
198
|
+
* @end: One of the ends of the pipe
|
|
199
|
+
*
|
|
200
|
+
* Return one of the ends of the pipe. It remains owned by @self.
|
|
201
|
+
*
|
|
202
|
+
* This function is async-signal safe (see [`signal(7)`](man:signal(7)) and
|
|
203
|
+
* [`signal-safety(7)`](man:signal-safety(7))), making it safe to call from a
|
|
204
|
+
* signal handler or a #GSpawnChildSetupFunc.
|
|
205
|
+
*
|
|
206
|
+
* This function preserves the value of `errno`.
|
|
207
|
+
*
|
|
208
|
+
* Returns: a non-negative file descriptor owned by @self, which must not
|
|
209
|
+
* be closed by the caller, or a negative number if the corresponding
|
|
210
|
+
* end of the pipe was already closed or stolen
|
|
211
|
+
*
|
|
212
|
+
* Since: 2.80
|
|
213
|
+
*/
|
|
214
|
+
GLIB_AVAILABLE_STATIC_INLINE_IN_2_80
|
|
215
|
+
static inline int
|
|
216
|
+
g_unix_pipe_get (GUnixPipe *self,
|
|
217
|
+
GUnixPipeEnd end)
|
|
218
|
+
{
|
|
219
|
+
return self->fds[end];
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
/**
|
|
223
|
+
* g_unix_pipe_steal:
|
|
224
|
+
* @self: A pair of file descriptors
|
|
225
|
+
* @end: One of the ends of the pipe
|
|
226
|
+
*
|
|
227
|
+
* Return one of the ends of the pipe. It becomes owned by the caller,
|
|
228
|
+
* and the file descriptor in the data structure is set to `-1`,
|
|
229
|
+
* similar to g_steal_fd().
|
|
230
|
+
*
|
|
231
|
+
* This function is async-signal safe (see [`signal(7)`](man:signal(7)) and
|
|
232
|
+
* [`signal-safety(7)`](man:signal-safety(7))), making it safe to call from a
|
|
233
|
+
* signal handler or a #GSpawnChildSetupFunc.
|
|
234
|
+
*
|
|
235
|
+
* This function preserves the value of `errno`.
|
|
236
|
+
*
|
|
237
|
+
* Returns: a non-negative file descriptor, which becomes owned by the
|
|
238
|
+
* caller and must be closed by the caller if required, or a negative
|
|
239
|
+
* number if the corresponding end of the pipe was already closed or stolen
|
|
240
|
+
*
|
|
241
|
+
* Since: 2.80
|
|
242
|
+
*/
|
|
243
|
+
GLIB_AVAILABLE_STATIC_INLINE_IN_2_80
|
|
244
|
+
static inline int
|
|
245
|
+
g_unix_pipe_steal (GUnixPipe *self,
|
|
246
|
+
GUnixPipeEnd end)
|
|
247
|
+
{
|
|
248
|
+
return g_steal_fd (&self->fds[end]);
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
/**
|
|
252
|
+
* g_unix_pipe_close:
|
|
253
|
+
* @self: A pair of file descriptors
|
|
254
|
+
* @end: One of the ends of the pipe
|
|
255
|
+
* @error: Optionally used to report an error on failure
|
|
256
|
+
*
|
|
257
|
+
* Close one of the ends of the pipe and set the relevant member of @fds
|
|
258
|
+
* to `-1` before returning, equivalent to g_clear_fd().
|
|
259
|
+
*
|
|
260
|
+
* Like g_close(), if closing the file descriptor fails, the error is
|
|
261
|
+
* stored in both %errno and @error. If this function succeeds,
|
|
262
|
+
* %errno is undefined.
|
|
263
|
+
*
|
|
264
|
+
* This function is async-signal safe if @error is %NULL and the relevant
|
|
265
|
+
* member of @fds is either negative or a valid open file descriptor.
|
|
266
|
+
* This makes it safe to call from a signal handler or a #GSpawnChildSetupFunc
|
|
267
|
+
* under those conditions.
|
|
268
|
+
* See [`signal(7)`](man:signal(7)) and
|
|
269
|
+
* [`signal-safety(7)`](man:signal-safety(7)) for more details.
|
|
270
|
+
*
|
|
271
|
+
* To close both file descriptors and ignore any errors, use
|
|
272
|
+
* g_unix_pipe_clear() instead.
|
|
273
|
+
*
|
|
274
|
+
* Returns: %TRUE on success
|
|
275
|
+
*
|
|
276
|
+
* Since: 2.80
|
|
277
|
+
*/
|
|
278
|
+
GLIB_AVAILABLE_STATIC_INLINE_IN_2_80
|
|
279
|
+
static inline gboolean
|
|
280
|
+
g_unix_pipe_close (GUnixPipe *self,
|
|
281
|
+
GUnixPipeEnd end,
|
|
282
|
+
GError **error)
|
|
283
|
+
{
|
|
284
|
+
return g_clear_fd (&self->fds[end], error);
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
/**
|
|
288
|
+
* g_unix_pipe_clear:
|
|
289
|
+
* @self: a #GUnixPipe
|
|
290
|
+
*
|
|
291
|
+
* Close both ends of the pipe, unless they have already been closed or
|
|
292
|
+
* stolen. Any errors are ignored: use g_unix_pipe_close() or g_clear_fd()
|
|
293
|
+
* if error-handling is required.
|
|
294
|
+
*
|
|
295
|
+
* This function is async-signal safe if @error is %NULL and each member
|
|
296
|
+
* of @fds are either negative or a valid open file descriptor.
|
|
297
|
+
* As a result, it is safe to call this function or use `g_auto(GUnixPipe)`
|
|
298
|
+
* (on compilers that support it) in a signal handler or a
|
|
299
|
+
* #GSpawnChildSetupFunc, as long as those conditions are ensured to be true.
|
|
300
|
+
* See [`signal(7)`](man:signal(7)) and
|
|
301
|
+
* [`signal-safety(7)`](man:signal-safety(7)) for more details.
|
|
302
|
+
*
|
|
303
|
+
* This function preserves the value of `errno`.
|
|
304
|
+
*
|
|
305
|
+
* Since: 2.80
|
|
306
|
+
*/
|
|
307
|
+
GLIB_AVAILABLE_STATIC_INLINE_IN_2_80
|
|
308
|
+
static inline void
|
|
309
|
+
g_unix_pipe_clear (GUnixPipe *self)
|
|
310
|
+
{
|
|
311
|
+
/* Don't overwrite thread-local errno if closing the fd fails */
|
|
312
|
+
int errsv = errno;
|
|
313
|
+
|
|
314
|
+
if (!g_unix_pipe_close (self, G_UNIX_PIPE_END_READ, NULL))
|
|
315
|
+
{
|
|
316
|
+
/* ignore */
|
|
317
|
+
}
|
|
318
|
+
|
|
319
|
+
if (!g_unix_pipe_close (self, G_UNIX_PIPE_END_WRITE, NULL))
|
|
320
|
+
{
|
|
321
|
+
/* ignore */
|
|
322
|
+
}
|
|
323
|
+
|
|
324
|
+
errno = errsv;
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
G_DEFINE_AUTO_CLEANUP_CLEAR_FUNC (GUnixPipe, g_unix_pipe_clear)
|
|
328
|
+
|
|
329
|
+
G_GNUC_END_IGNORE_DEPRECATIONS
|
|
330
|
+
|
|
123
331
|
G_END_DECLS
|
|
124
332
|
|
|
125
333
|
#endif /* __G_UNIX_H__ */
|
|
@@ -950,3 +950,37 @@
|
|
|
950
950
|
#define GMODULE_AVAILABLE_ENUMERATOR_IN_2_78
|
|
951
951
|
#define GMODULE_AVAILABLE_TYPE_IN_2_78
|
|
952
952
|
#endif
|
|
953
|
+
|
|
954
|
+
#if GLIB_VERSION_MIN_REQUIRED >= GLIB_VERSION_2_80
|
|
955
|
+
#define GMODULE_DEPRECATED_IN_2_80 GMODULE_DEPRECATED
|
|
956
|
+
#define GMODULE_DEPRECATED_IN_2_80_FOR(f) GMODULE_DEPRECATED_FOR (f)
|
|
957
|
+
#define GMODULE_DEPRECATED_MACRO_IN_2_80 GLIB_DEPRECATED_MACRO
|
|
958
|
+
#define GMODULE_DEPRECATED_MACRO_IN_2_80_FOR(f) GLIB_DEPRECATED_MACRO_FOR (f)
|
|
959
|
+
#define GMODULE_DEPRECATED_ENUMERATOR_IN_2_80 GLIB_DEPRECATED_ENUMERATOR
|
|
960
|
+
#define GMODULE_DEPRECATED_ENUMERATOR_IN_2_80_FOR(f) GLIB_DEPRECATED_ENUMERATOR_FOR (f)
|
|
961
|
+
#define GMODULE_DEPRECATED_TYPE_IN_2_80 GLIB_DEPRECATED_TYPE
|
|
962
|
+
#define GMODULE_DEPRECATED_TYPE_IN_2_80_FOR(f) GLIB_DEPRECATED_TYPE_FOR (f)
|
|
963
|
+
#else
|
|
964
|
+
#define GMODULE_DEPRECATED_IN_2_80 _GMODULE_EXTERN
|
|
965
|
+
#define GMODULE_DEPRECATED_IN_2_80_FOR(f) _GMODULE_EXTERN
|
|
966
|
+
#define GMODULE_DEPRECATED_MACRO_IN_2_80
|
|
967
|
+
#define GMODULE_DEPRECATED_MACRO_IN_2_80_FOR(f)
|
|
968
|
+
#define GMODULE_DEPRECATED_ENUMERATOR_IN_2_80
|
|
969
|
+
#define GMODULE_DEPRECATED_ENUMERATOR_IN_2_80_FOR(f)
|
|
970
|
+
#define GMODULE_DEPRECATED_TYPE_IN_2_80
|
|
971
|
+
#define GMODULE_DEPRECATED_TYPE_IN_2_80_FOR(f)
|
|
972
|
+
#endif
|
|
973
|
+
|
|
974
|
+
#if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_80
|
|
975
|
+
#define GMODULE_AVAILABLE_IN_2_80 GMODULE_UNAVAILABLE (2, 80)
|
|
976
|
+
#define GMODULE_AVAILABLE_STATIC_INLINE_IN_2_80 GLIB_UNAVAILABLE_STATIC_INLINE (2, 80)
|
|
977
|
+
#define GMODULE_AVAILABLE_MACRO_IN_2_80 GLIB_UNAVAILABLE_MACRO (2, 80)
|
|
978
|
+
#define GMODULE_AVAILABLE_ENUMERATOR_IN_2_80 GLIB_UNAVAILABLE_ENUMERATOR (2, 80)
|
|
979
|
+
#define GMODULE_AVAILABLE_TYPE_IN_2_80 GLIB_UNAVAILABLE_TYPE (2, 80)
|
|
980
|
+
#else
|
|
981
|
+
#define GMODULE_AVAILABLE_IN_2_80 _GMODULE_EXTERN
|
|
982
|
+
#define GMODULE_AVAILABLE_STATIC_INLINE_IN_2_80
|
|
983
|
+
#define GMODULE_AVAILABLE_MACRO_IN_2_80
|
|
984
|
+
#define GMODULE_AVAILABLE_ENUMERATOR_IN_2_80
|
|
985
|
+
#define GMODULE_AVAILABLE_TYPE_IN_2_80
|
|
986
|
+
#endif
|
|
@@ -38,14 +38,6 @@ G_BEGIN_DECLS
|
|
|
38
38
|
#define G_BINDING(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), G_TYPE_BINDING, GBinding))
|
|
39
39
|
#define G_IS_BINDING(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), G_TYPE_BINDING))
|
|
40
40
|
|
|
41
|
-
/**
|
|
42
|
-
* GBinding:
|
|
43
|
-
*
|
|
44
|
-
* GBinding is an opaque structure whose members
|
|
45
|
-
* cannot be accessed directly.
|
|
46
|
-
*
|
|
47
|
-
* Since: 2.26
|
|
48
|
-
*/
|
|
49
41
|
typedef struct _GBinding GBinding;
|
|
50
42
|
|
|
51
43
|
/**
|
|
@@ -36,14 +36,6 @@ G_BEGIN_DECLS
|
|
|
36
36
|
#define G_IS_BINDING_GROUP(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), G_TYPE_BINDING_GROUP))
|
|
37
37
|
#define G_TYPE_BINDING_GROUP (g_binding_group_get_type())
|
|
38
38
|
|
|
39
|
-
/**
|
|
40
|
-
* GBindingGroup:
|
|
41
|
-
*
|
|
42
|
-
* GBindingGroup is an opaque structure whose members
|
|
43
|
-
* cannot be accessed directly.
|
|
44
|
-
*
|
|
45
|
-
* Since: 2.72
|
|
46
|
-
*/
|
|
47
39
|
typedef struct _GBindingGroup GBindingGroup;
|
|
48
40
|
|
|
49
41
|
GOBJECT_AVAILABLE_IN_2_72
|
|
@@ -169,15 +169,7 @@ struct _GClosureNotifyData
|
|
|
169
169
|
gpointer data;
|
|
170
170
|
GClosureNotify notify;
|
|
171
171
|
};
|
|
172
|
-
|
|
173
|
-
* GClosure:
|
|
174
|
-
* @in_marshal: Indicates whether the closure is currently being invoked with
|
|
175
|
-
* g_closure_invoke()
|
|
176
|
-
* @is_invalid: Indicates whether the closure has been invalidated by
|
|
177
|
-
* g_closure_invalidate()
|
|
178
|
-
*
|
|
179
|
-
* A #GClosure represents a callback supplied by the programmer.
|
|
180
|
-
*/
|
|
172
|
+
|
|
181
173
|
struct _GClosure
|
|
182
174
|
{
|
|
183
175
|
/*< private >*/
|
|
@@ -327,6 +327,33 @@ typedef gsize GType;
|
|
|
327
327
|
*/
|
|
328
328
|
#define G_TYPE_BOOKMARK_FILE (g_bookmark_file_get_type ())
|
|
329
329
|
|
|
330
|
+
/**
|
|
331
|
+
* G_TYPE_HMAC:
|
|
332
|
+
*
|
|
333
|
+
* The #GType for a boxed type holding a #GHmac.
|
|
334
|
+
*
|
|
335
|
+
* Since: 2.80
|
|
336
|
+
*/
|
|
337
|
+
#define G_TYPE_HMAC (g_hmac_get_type ())
|
|
338
|
+
|
|
339
|
+
/**
|
|
340
|
+
* G_TYPE_DIR:
|
|
341
|
+
*
|
|
342
|
+
* The #GType for a boxed type holding a #GDir.
|
|
343
|
+
*
|
|
344
|
+
* Since: 2.80
|
|
345
|
+
*/
|
|
346
|
+
#define G_TYPE_DIR (g_dir_get_type ())
|
|
347
|
+
|
|
348
|
+
/**
|
|
349
|
+
* G_TYPE_STRV_BUILDER:
|
|
350
|
+
*
|
|
351
|
+
* The #GType for a boxed type holding a #GStrvBuilder.
|
|
352
|
+
*
|
|
353
|
+
* Since: 2.80
|
|
354
|
+
*/
|
|
355
|
+
#define G_TYPE_STRV_BUILDER (g_strv_builder_get_type ())
|
|
356
|
+
|
|
330
357
|
GOBJECT_AVAILABLE_IN_ALL
|
|
331
358
|
GType g_date_get_type (void) G_GNUC_CONST;
|
|
332
359
|
GOBJECT_AVAILABLE_IN_ALL
|
|
@@ -391,6 +418,12 @@ GOBJECT_AVAILABLE_IN_2_70
|
|
|
391
418
|
GType g_pattern_spec_get_type (void) G_GNUC_CONST;
|
|
392
419
|
GOBJECT_AVAILABLE_IN_2_76
|
|
393
420
|
GType g_bookmark_file_get_type (void) G_GNUC_CONST;
|
|
421
|
+
GOBJECT_AVAILABLE_IN_2_80
|
|
422
|
+
GType g_hmac_get_type (void) G_GNUC_CONST;
|
|
423
|
+
GOBJECT_AVAILABLE_IN_2_80
|
|
424
|
+
GType g_dir_get_type (void) G_GNUC_CONST;
|
|
425
|
+
GOBJECT_AVAILABLE_IN_2_80
|
|
426
|
+
GType g_strv_builder_get_type (void) G_GNUC_CONST;
|
|
394
427
|
|
|
395
428
|
GOBJECT_DEPRECATED_FOR('G_TYPE_VARIANT')
|
|
396
429
|
GType g_variant_get_gtype (void) G_GNUC_CONST;
|
|
@@ -23,6 +23,8 @@
|
|
|
23
23
|
#error "Only <glib-object.h> can be included directly."
|
|
24
24
|
#endif
|
|
25
25
|
|
|
26
|
+
#ifndef __GI_SCANNER__
|
|
27
|
+
|
|
26
28
|
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GClosure, g_closure_unref)
|
|
27
29
|
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GEnumClass, g_type_class_unref)
|
|
28
30
|
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GFlagsClass, g_type_class_unref)
|
|
@@ -31,3 +33,5 @@ G_DEFINE_AUTOPTR_CLEANUP_FUNC(GInitiallyUnowned, g_object_unref)
|
|
|
31
33
|
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GParamSpec, g_param_spec_unref)
|
|
32
34
|
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GTypeClass, g_type_class_unref)
|
|
33
35
|
G_DEFINE_AUTO_CLEANUP_CLEAR_FUNC(GValue, g_value_unset)
|
|
36
|
+
|
|
37
|
+
#endif /* __GI_SCANNER__ */
|
|
@@ -950,3 +950,37 @@
|
|
|
950
950
|
#define GOBJECT_AVAILABLE_ENUMERATOR_IN_2_78
|
|
951
951
|
#define GOBJECT_AVAILABLE_TYPE_IN_2_78
|
|
952
952
|
#endif
|
|
953
|
+
|
|
954
|
+
#if GLIB_VERSION_MIN_REQUIRED >= GLIB_VERSION_2_80
|
|
955
|
+
#define GOBJECT_DEPRECATED_IN_2_80 GOBJECT_DEPRECATED
|
|
956
|
+
#define GOBJECT_DEPRECATED_IN_2_80_FOR(f) GOBJECT_DEPRECATED_FOR (f)
|
|
957
|
+
#define GOBJECT_DEPRECATED_MACRO_IN_2_80 GLIB_DEPRECATED_MACRO
|
|
958
|
+
#define GOBJECT_DEPRECATED_MACRO_IN_2_80_FOR(f) GLIB_DEPRECATED_MACRO_FOR (f)
|
|
959
|
+
#define GOBJECT_DEPRECATED_ENUMERATOR_IN_2_80 GLIB_DEPRECATED_ENUMERATOR
|
|
960
|
+
#define GOBJECT_DEPRECATED_ENUMERATOR_IN_2_80_FOR(f) GLIB_DEPRECATED_ENUMERATOR_FOR (f)
|
|
961
|
+
#define GOBJECT_DEPRECATED_TYPE_IN_2_80 GLIB_DEPRECATED_TYPE
|
|
962
|
+
#define GOBJECT_DEPRECATED_TYPE_IN_2_80_FOR(f) GLIB_DEPRECATED_TYPE_FOR (f)
|
|
963
|
+
#else
|
|
964
|
+
#define GOBJECT_DEPRECATED_IN_2_80 _GOBJECT_EXTERN
|
|
965
|
+
#define GOBJECT_DEPRECATED_IN_2_80_FOR(f) _GOBJECT_EXTERN
|
|
966
|
+
#define GOBJECT_DEPRECATED_MACRO_IN_2_80
|
|
967
|
+
#define GOBJECT_DEPRECATED_MACRO_IN_2_80_FOR(f)
|
|
968
|
+
#define GOBJECT_DEPRECATED_ENUMERATOR_IN_2_80
|
|
969
|
+
#define GOBJECT_DEPRECATED_ENUMERATOR_IN_2_80_FOR(f)
|
|
970
|
+
#define GOBJECT_DEPRECATED_TYPE_IN_2_80
|
|
971
|
+
#define GOBJECT_DEPRECATED_TYPE_IN_2_80_FOR(f)
|
|
972
|
+
#endif
|
|
973
|
+
|
|
974
|
+
#if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_80
|
|
975
|
+
#define GOBJECT_AVAILABLE_IN_2_80 GOBJECT_UNAVAILABLE (2, 80)
|
|
976
|
+
#define GOBJECT_AVAILABLE_STATIC_INLINE_IN_2_80 GLIB_UNAVAILABLE_STATIC_INLINE (2, 80)
|
|
977
|
+
#define GOBJECT_AVAILABLE_MACRO_IN_2_80 GLIB_UNAVAILABLE_MACRO (2, 80)
|
|
978
|
+
#define GOBJECT_AVAILABLE_ENUMERATOR_IN_2_80 GLIB_UNAVAILABLE_ENUMERATOR (2, 80)
|
|
979
|
+
#define GOBJECT_AVAILABLE_TYPE_IN_2_80 GLIB_UNAVAILABLE_TYPE (2, 80)
|
|
980
|
+
#else
|
|
981
|
+
#define GOBJECT_AVAILABLE_IN_2_80 _GOBJECT_EXTERN
|
|
982
|
+
#define GOBJECT_AVAILABLE_STATIC_INLINE_IN_2_80
|
|
983
|
+
#define GOBJECT_AVAILABLE_MACRO_IN_2_80
|
|
984
|
+
#define GOBJECT_AVAILABLE_ENUMERATOR_IN_2_80
|
|
985
|
+
#define GOBJECT_AVAILABLE_TYPE_IN_2_80
|
|
986
|
+
#endif
|
|
@@ -248,22 +248,7 @@ typedef void (*GObjectFinalizeFunc) (GObject *object);
|
|
|
248
248
|
*/
|
|
249
249
|
typedef void (*GWeakNotify) (gpointer data,
|
|
250
250
|
GObject *where_the_object_was);
|
|
251
|
-
|
|
252
|
-
* GObject:
|
|
253
|
-
*
|
|
254
|
-
* The base object type.
|
|
255
|
-
*
|
|
256
|
-
* All the fields in the `GObject` structure are private to the implementation
|
|
257
|
-
* and should never be accessed directly.
|
|
258
|
-
*
|
|
259
|
-
* Since GLib 2.72, all #GObjects are guaranteed to be aligned to at least the
|
|
260
|
-
* alignment of the largest basic GLib type (typically this is #guint64 or
|
|
261
|
-
* #gdouble). If you need larger alignment for an element in a #GObject, you
|
|
262
|
-
* should allocate it on the heap (aligned), or arrange for your #GObject to be
|
|
263
|
-
* appropriately padded. This guarantee applies to the #GObject (or derived)
|
|
264
|
-
* struct, the #GObjectClass (or derived) struct, and any private data allocated
|
|
265
|
-
* by G_ADD_PRIVATE().
|
|
266
|
-
*/
|
|
251
|
+
|
|
267
252
|
struct _GObject
|
|
268
253
|
{
|
|
269
254
|
GTypeInstance g_type_instance;
|
|
@@ -203,17 +203,7 @@ typedef struct _GParamSpec GParamSpec;
|
|
|
203
203
|
typedef struct _GParamSpecClass GParamSpecClass;
|
|
204
204
|
typedef struct _GParameter GParameter GOBJECT_DEPRECATED_TYPE_IN_2_54;
|
|
205
205
|
typedef struct _GParamSpecPool GParamSpecPool;
|
|
206
|
-
|
|
207
|
-
* GParamSpec: (ref-func g_param_spec_ref_sink) (unref-func g_param_spec_unref) (set-value-func g_value_set_param) (get-value-func g_value_get_param)
|
|
208
|
-
* @g_type_instance: private #GTypeInstance portion
|
|
209
|
-
* @name: name of this parameter: always an interned string
|
|
210
|
-
* @flags: #GParamFlags flags for this parameter
|
|
211
|
-
* @value_type: the #GValue type for this parameter
|
|
212
|
-
* @owner_type: #GType type that uses (introduces) this parameter
|
|
213
|
-
*
|
|
214
|
-
* All other fields of the GParamSpec struct are private and
|
|
215
|
-
* should not be used directly.
|
|
216
|
-
*/
|
|
206
|
+
|
|
217
207
|
struct _GParamSpec
|
|
218
208
|
{
|
|
219
209
|
GTypeInstance g_type_instance;
|
|
@@ -454,7 +444,8 @@ GOBJECT_AVAILABLE_IN_ALL
|
|
|
454
444
|
GParamSpec** g_param_spec_pool_list (GParamSpecPool *pool,
|
|
455
445
|
GType owner_type,
|
|
456
446
|
guint *n_pspecs_p);
|
|
457
|
-
|
|
447
|
+
GOBJECT_AVAILABLE_IN_2_80
|
|
448
|
+
void g_param_spec_pool_free (GParamSpecPool *pool);
|
|
458
449
|
|
|
459
450
|
/* contracts:
|
|
460
451
|
*
|
|
@@ -504,7 +504,7 @@ void g_signal_chain_from_overridden_handler (gpointer instance,
|
|
|
504
504
|
*
|
|
505
505
|
* The handler will be called synchronously, before the default handler of the signal. g_signal_emit() will not return control until all handlers are called.
|
|
506
506
|
*
|
|
507
|
-
* See [memory management of signal handlers][
|
|
507
|
+
* See [memory management of signal handlers][signals.html#Memory_management_of_signal_handlers] for
|
|
508
508
|
* details on how to handle the return value and memory management of @data.
|
|
509
509
|
*
|
|
510
510
|
* Returns: the handler ID, of type #gulong (always greater than 0 for successful connections)
|
|
@@ -36,14 +36,6 @@ G_BEGIN_DECLS
|
|
|
36
36
|
#define G_IS_SIGNAL_GROUP(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), G_TYPE_SIGNAL_GROUP))
|
|
37
37
|
#define G_TYPE_SIGNAL_GROUP (g_signal_group_get_type())
|
|
38
38
|
|
|
39
|
-
/**
|
|
40
|
-
* GSignalGroup:
|
|
41
|
-
*
|
|
42
|
-
* #GSignalGroup is an opaque structure whose members
|
|
43
|
-
* cannot be accessed directly.
|
|
44
|
-
*
|
|
45
|
-
* Since: 2.72
|
|
46
|
-
*/
|
|
47
39
|
typedef struct _GSignalGroup GSignalGroup;
|
|
48
40
|
|
|
49
41
|
GOBJECT_AVAILABLE_IN_2_72
|
|
@@ -421,9 +421,11 @@ G_BEGIN_DECLS
|
|
|
421
421
|
* A numerical value which represents the unique identifier of a registered
|
|
422
422
|
* type.
|
|
423
423
|
*/
|
|
424
|
-
#if
|
|
424
|
+
#if GLIB_SIZEOF_VOID_P > GLIB_SIZEOF_SIZE_T
|
|
425
|
+
typedef guintptr GType;
|
|
426
|
+
#elif GLIB_SIZEOF_SIZE_T != GLIB_SIZEOF_LONG || !defined (G_CXX_STD_VERSION)
|
|
425
427
|
typedef gsize GType;
|
|
426
|
-
#else /* for historic reasons, C++ links against gulong GTypes */
|
|
428
|
+
#else /* for historic reasons, C++ on non-Morello/CHERI systems links against gulong GTypes */
|
|
427
429
|
typedef gulong GType;
|
|
428
430
|
#endif
|
|
429
431
|
typedef struct _GValue GValue;
|
|
@@ -2009,8 +2011,8 @@ guint g_type_get_type_registration_serial (void);
|
|
|
2009
2011
|
* GType
|
|
2010
2012
|
* gtk_gadget_get_type (void)
|
|
2011
2013
|
* {
|
|
2012
|
-
* static
|
|
2013
|
-
* if (
|
|
2014
|
+
* static GType static_g_define_type_id = 0;
|
|
2015
|
+
* if (g_once_init_enter_pointer (&static_g_define_type_id))
|
|
2014
2016
|
* {
|
|
2015
2017
|
* GType g_define_type_id =
|
|
2016
2018
|
* g_type_register_static_simple (GTK_TYPE_WIDGET,
|
|
@@ -2030,7 +2032,7 @@ guint g_type_get_type_registration_serial (void);
|
|
|
2030
2032
|
* };
|
|
2031
2033
|
* g_type_add_interface_static (g_define_type_id, TYPE_GIZMO, &g_implement_interface_info);
|
|
2032
2034
|
* }
|
|
2033
|
-
*
|
|
2035
|
+
* g_once_init_leave_pointer (&static_g_define_type_id, g_define_type_id);
|
|
2034
2036
|
* }
|
|
2035
2037
|
* return static_g_define_type_id;
|
|
2036
2038
|
* }
|
|
@@ -2267,6 +2269,16 @@ static void type_name##_class_intern_init (gpointer klass, \
|
|
|
2267
2269
|
}
|
|
2268
2270
|
#endif /* GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38 */
|
|
2269
2271
|
|
|
2272
|
+
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_80
|
|
2273
|
+
#define _g_type_once_init_type GType
|
|
2274
|
+
#define _g_type_once_init_enter g_once_init_enter_pointer
|
|
2275
|
+
#define _g_type_once_init_leave g_once_init_leave_pointer
|
|
2276
|
+
#else /* if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_80 */
|
|
2277
|
+
#define _g_type_once_init_type gsize
|
|
2278
|
+
#define _g_type_once_init_enter g_once_init_enter
|
|
2279
|
+
#define _g_type_once_init_leave g_once_init_leave
|
|
2280
|
+
#endif /* GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_80 */
|
|
2281
|
+
|
|
2270
2282
|
/* Added for _G_DEFINE_TYPE_EXTENDED_WITH_PRELUDE */
|
|
2271
2283
|
#define _G_DEFINE_TYPE_EXTENDED_BEGIN_PRE(TypeName, type_name, TYPE_PARENT) \
|
|
2272
2284
|
\
|
|
@@ -2293,15 +2305,15 @@ type_name##_get_instance_private (TypeName *self) \
|
|
|
2293
2305
|
GType \
|
|
2294
2306
|
type_name##_get_type (void) \
|
|
2295
2307
|
{ \
|
|
2296
|
-
static
|
|
2308
|
+
static _g_type_once_init_type static_g_define_type_id = 0;
|
|
2297
2309
|
/* Prelude goes here */
|
|
2298
2310
|
|
|
2299
2311
|
/* Added for _G_DEFINE_TYPE_EXTENDED_WITH_PRELUDE */
|
|
2300
2312
|
#define _G_DEFINE_TYPE_EXTENDED_BEGIN_REGISTER(TypeName, type_name, TYPE_PARENT, flags) \
|
|
2301
|
-
if (
|
|
2313
|
+
if (_g_type_once_init_enter (&static_g_define_type_id)) \
|
|
2302
2314
|
{ \
|
|
2303
2315
|
GType g_define_type_id = type_name##_get_type_once (); \
|
|
2304
|
-
|
|
2316
|
+
_g_type_once_init_leave (&static_g_define_type_id, g_define_type_id); \
|
|
2305
2317
|
} \
|
|
2306
2318
|
return static_g_define_type_id; \
|
|
2307
2319
|
} /* closes type_name##_get_type() */ \
|
|
@@ -2346,8 +2358,8 @@ static void type_name##_default_init_adapter (TypeName##Interface *klass, \
|
|
|
2346
2358
|
GType \
|
|
2347
2359
|
type_name##_get_type (void) \
|
|
2348
2360
|
{ \
|
|
2349
|
-
static
|
|
2350
|
-
if (
|
|
2361
|
+
static _g_type_once_init_type static_g_define_type_id = 0; \
|
|
2362
|
+
if (_g_type_once_init_enter (&static_g_define_type_id)) \
|
|
2351
2363
|
{ \
|
|
2352
2364
|
GType g_define_type_id = \
|
|
2353
2365
|
g_type_register_static_simple (G_TYPE_INTERFACE, \
|
|
@@ -2363,7 +2375,7 @@ type_name##_get_type (void) \
|
|
|
2363
2375
|
#define _G_DEFINE_INTERFACE_EXTENDED_END() \
|
|
2364
2376
|
/* following custom code */ \
|
|
2365
2377
|
} \
|
|
2366
|
-
|
|
2378
|
+
_g_type_once_init_leave (&static_g_define_type_id, g_define_type_id); \
|
|
2367
2379
|
} \
|
|
2368
2380
|
return static_g_define_type_id; \
|
|
2369
2381
|
} /* closes type_name##_get_type() */
|
|
@@ -2472,11 +2484,11 @@ static GType type_name##_get_type_once (void); \
|
|
|
2472
2484
|
GType \
|
|
2473
2485
|
type_name##_get_type (void) \
|
|
2474
2486
|
{ \
|
|
2475
|
-
static
|
|
2476
|
-
if (
|
|
2487
|
+
static _g_type_once_init_type static_g_define_type_id = 0; \
|
|
2488
|
+
if (_g_type_once_init_enter (&static_g_define_type_id)) \
|
|
2477
2489
|
{ \
|
|
2478
2490
|
GType g_define_type_id = type_name##_get_type_once (); \
|
|
2479
|
-
|
|
2491
|
+
_g_type_once_init_leave (&static_g_define_type_id, g_define_type_id); \
|
|
2480
2492
|
} \
|
|
2481
2493
|
return static_g_define_type_id; \
|
|
2482
2494
|
} \
|
|
@@ -2509,11 +2521,11 @@ static GType type_name##_get_type_once (void); \
|
|
|
2509
2521
|
GType \
|
|
2510
2522
|
type_name##_get_type (void) \
|
|
2511
2523
|
{ \
|
|
2512
|
-
static
|
|
2513
|
-
if (
|
|
2524
|
+
static _g_type_once_init_type static_g_define_type_id = 0; \
|
|
2525
|
+
if (_g_type_once_init_enter (&static_g_define_type_id)) \
|
|
2514
2526
|
{ \
|
|
2515
2527
|
GType g_define_type_id = type_name##_get_type_once (); \
|
|
2516
|
-
|
|
2528
|
+
_g_type_once_init_leave (&static_g_define_type_id, g_define_type_id); \
|
|
2517
2529
|
} \
|
|
2518
2530
|
return static_g_define_type_id; \
|
|
2519
2531
|
} \
|
|
@@ -2562,11 +2574,11 @@ static GType type_name##_get_type_once (void); \
|
|
|
2562
2574
|
GType \
|
|
2563
2575
|
type_name##_get_type (void) \
|
|
2564
2576
|
{ \
|
|
2565
|
-
static
|
|
2566
|
-
if (
|
|
2577
|
+
static _g_type_once_init_type static_g_define_type_id = 0; \
|
|
2578
|
+
if (_g_type_once_init_enter (&static_g_define_type_id)) \
|
|
2567
2579
|
{ \
|
|
2568
2580
|
GType g_define_type_id = type_name##_get_type_once (); \
|
|
2569
|
-
|
|
2581
|
+
_g_type_once_init_leave (&static_g_define_type_id, g_define_type_id); \
|
|
2570
2582
|
} \
|
|
2571
2583
|
return static_g_define_type_id; \
|
|
2572
2584
|
} \
|
|
@@ -2710,6 +2722,27 @@ const gchar * g_type_name_from_class (GTypeClass *g_class);
|
|
|
2710
2722
|
*/
|
|
2711
2723
|
#define G_TYPE_FLAG_RESERVED_ID_BIT ((GType) (1 << 0))
|
|
2712
2724
|
|
|
2725
|
+
/**
|
|
2726
|
+
* GPOINTER_TO_TYPE:
|
|
2727
|
+
* @p: The pointer to convert to a #GType
|
|
2728
|
+
*
|
|
2729
|
+
* This macro should be used instead of GPOINTER_TO_SIZE() to ensure
|
|
2730
|
+
* portability since #GType is not guaranteed to be the same as #gsize.
|
|
2731
|
+
*
|
|
2732
|
+
* Since: 2.80
|
|
2733
|
+
*/
|
|
2734
|
+
#define GPOINTER_TO_TYPE(p) ((GType) (guintptr) (p)) GOBJECT_AVAILABLE_MACRO_IN_2_80
|
|
2735
|
+
/**
|
|
2736
|
+
* GTYPE_TO_POINTER:
|
|
2737
|
+
* @t: The #GType to convert to a pointer
|
|
2738
|
+
*
|
|
2739
|
+
* This macro should be used instead of GSIZE_TO_POINTER() to ensure
|
|
2740
|
+
* portability since #GType is not guaranteed to be the same as #gsize.
|
|
2741
|
+
*
|
|
2742
|
+
* Since: 2.80
|
|
2743
|
+
*/
|
|
2744
|
+
#define GTYPE_TO_POINTER(t) ((gpointer) (guintptr) (t)) GOBJECT_AVAILABLE_MACRO_IN_2_80
|
|
2745
|
+
|
|
2713
2746
|
G_END_DECLS
|
|
2714
2747
|
|
|
2715
2748
|
#endif /* __G_TYPE_H__ */
|