3 (defcfun gdk-threads-init
:void
)
4 (glib:at-init
() (gdk-threads-init))
6 (defcfun gdk-threads-enter
:void
)
7 (export 'gdk-threads-enter
)
9 (defcfun gdk-threads-leave
:void
)
10 (export 'gdk-threads-leave
)
12 (defmacro with-gdk-threads-lock
(&body body
)
17 (gdk-threads-leave))))
18 (export 'with-gdk-threads-lock
)
21 ;; void gdk_threads_set_lock_functions (GCallback enter_fn,
22 ;; GCallback leave_fn);
24 (defcallback source-func-callback
:boolean
26 (funcall (stable-pointer-value data
)))
28 (defcallback stable-pointer-free-destroy-notify-callback
:void
((data :pointer
))
29 (free-stable-pointer data
))
31 (defcfun gdk_threads_add_idle_full
:uint
35 (destroy-notify :pointer
))
37 (defun gdk-threads-add-idle-full (priority function
)
38 (gdk_threads_add_idle_full priority
39 (callback source-func-callback
)
40 (allocate-stable-pointer function
)
41 (callback stable-pointer-free-destroy-notify-callback
)))
43 (export 'gdk-threads-add-idle-full
)
45 (defcfun gdk_threads_add_timeout_full
:uint
50 (destroy-notify :pointer
))
52 (defun gdk-threads-add-timeout-full (priority interval-msec function
)
53 (gdk_threads_add_timeout_full priority interval-msec
54 (callback source-func-callback
)
55 (allocate-stable-pointer function
)
56 (callback stable-pointer-free-destroy-notify-callback
)))
58 (export 'gdk-threads-add-timeout-full
)
60 (defcfun gdk_threads_add_timeout_seconds_full
:uint
65 (destroy-notify :pointer
))
67 (defun gdk-threads-add-timeout-seconds-full (priority interval-sec function
)
68 (gdk_threads_add_timeout_seconds_full priority interval-sec
69 (callback source-func-callback
)
70 (allocate-stable-pointer function
)
71 (callback stable-pointer-free-destroy-notify-callback
)))
73 (export 'gdk-threads-add-timeout-seconds-full
)