pub type GSourceFunc = Option<unsafe extern "C" fn(user_data: gpointer) -> gboolean>;
Expand description
GSourceFunc: @user_data: data passed to the function, set when the source was created with one of the above functions
Specifies the type of function passed to g_timeout_add(), g_timeout_add_full(), g_idle_add(), and g_idle_add_full().
When calling g_source_set_callback(), you may need to cast a function of a different type to this type. Use G_SOURCE_FUNC() to avoid warnings about incompatible function types.
Returns: %FALSE if the source should be removed. %G_SOURCE_CONTINUE and %G_SOURCE_REMOVE are more memorable names for the return value.
Aliased Type§
enum GSourceFunc {
None,
Some(unsafe extern "C" fn(*mut c_void) -> i32),
}