Re: GtkBuilder Public API - Last call



On Thu, 14 Jun 2007, Johan Dahlin wrote:

Tim Janik wrote:

there could conceivably be new flags in the future. also,
"object" is different from "swapped". the former should use
g_signal_connect_object which needs a GObject argument and
auto-disconnects the signal handler if the object argument
is disposed. the later also works for void* pointers.

Oh, I knew I missed something.

Let's use this xml attributes for the signal tag;

 name: signal name
 handler: handler to connect the signal to
 after: optional, boolean if True, set flags to G_CONNECT_AFTER
 swapped: optional, boolean if True, set flags to G_CONNECT_SWAPPED
 object: optional, if set use g_signal_connect_object

user_type and user_data which I proposed doesn't make too much sense, it's
also difficult to support since you can't (AFAICT) use a GValue as user data.

g_signal_connect_object does not provide a way to send in user data so it
conflicts with the user data which may be passed in to
gtk_builder_connect_signals.

well, to be more precise, g_signal_connect_object hardcodes the assumption
that user_data is_a GObject*.

Not a too big deal I guess, it just needs to be
documented.

Johan


---
ciaoTJ



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