Function

GObjectCClosurenew_swap

Declaration

GClosure*
g_cclosure_new_swap (
  GCallback callback_func,
  gpointer user_data,
  GClosureNotify destroy_data
)

Description

Creates a new closure which invokes callback_func with user_data as the first parameter.

destroy_data will be called as a finalize notifier on the GClosure.

Parameters

callback_func GCallback
 

The function to invoke.

user_data gpointer
 

User data to pass to callback_func.

destroy_data GClosureNotify
 

Destroy notify to be called when user_data is no longer used.

Return value

Returns: GClosure
 

A floating reference to a new GCClosure.

 The data is owned by the called function.