Method

GObjectClosureadd_marshal_guards

Declaration

void
g_closure_add_marshal_guards (
  GClosure* closure,
  gpointer pre_marshal_data,
  GClosureNotify pre_marshal_notify,
  gpointer post_marshal_data,
  GClosureNotify post_marshal_notify
)

Description

Adds a pair of notifiers which get invoked before and after the closure callback, respectively.

This is typically used to protect the extra arguments for the duration of the callback. See g_object_watch_closure() for an example of marshal guards.

Parameters

pre_marshal_data gpointer
 

Data to pass to pre_marshal_notify.

pre_marshal_notify GClosureNotify
 

A function to call before the closure callback.

post_marshal_data gpointer
 

Data to pass to post_marshal_notify.

post_marshal_notify GClosureNotify
 

A function to call after the closure callback.