Re: [gtk-list] Re: new signal GtkWidget::user_signal?



On Mon, 26 Jan 1998, Nathan Carl Summers wrote:

> On Sun, 25 Jan 1998, Tim Janik wrote:
> 
> > 				     gint       user_type,
> > 
> > user_type is meant to distinguish different signal emissions by passing
> > a.g. an enumeration value that MySignalFunc() could switch() on.
> 
> Wouldn't a string be a better choice?  Things like this often get
> confused.  You know, libbloat uses 1234 to signal new memory to fill while
> libuglymath uses it to signal that the big math problem is done while
> libuseless signals it randomly and you can't figure out why, etc, etc.

a string would certainly be more desiptive, but would cause
a lot of strcmp()s in the callback function.

> 
> Or maybe something like
> gtk_signal_connect(... "user_signal::bigproblemfinished" ...)
this is not possible with current signal creation/dispatching hash
tables. i would have suggested this kind of signal addition if it
wouldn't require a major overhaul of the signal code.

> 
> Rockwalrus
> 

---
ciaoTJ



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