Re: GtkBuilder Public API - Last call



Hi,

I'm wondering if there is a reason why one cannot provide user_data
for gtk_builder_connect_signals? This data would be used as user_data
for each signal connected, except for those where a specific data widget
is defined in the glade-file. Currently the data used in signal connection
is either NULL or widget pointer specified in the .glade.

Of course one can use connect_full variant to achieve this, but that
also means that GModule-related code needs to be written into app.

-Markku-

Lainaus Johan Dahlin <jdahlin async com br>:

> /**
>  * gtk_builder_connect_signals:
>  * @builder: a #GtkBuilder
>  *
>  * This method is a simpler variation of
> gtk_builder_connect_signals_full().
>  * It uses #GModule's introspective features (by opening the module %NULL)
> to
>  * look at the application's symbol table.  From here it tries to match
>  * the signal handler names given in the interface description with
>  * symbols in the application and connects the signals.
>  *
>  * Note that this function will not work correctly if #GModule is not
>  * supported on the platform.
>  *
>  * Since: 2.12
>  **/
> void         gtk_builder_connect_signals         (GtkBuilder   *builder);
> 
> /**
>  * gtk_builder_connect_signals_full:
>  * @builder: a #GtkBuilder
>  * @func: the function used to connect the signals.
>  * @user_data: arbitrary data that will be passed to the connection
> function.
>  *
>  * This function can be thought of the interpeted language binding
>  * version of gtk_builder_signal_autoconnect(), except that it does not
>  * require gmodule to function correctly.
>  *
>  * Since: 2.12
>  */
> void         gtk_builder_connect_signals_full    (GtkBuilder   *builder,
>                                                   GtkBuilderConnectFunc
> func,
>                                                   gpointer      user_data);
> 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]