Re: What's purpose of returned boolean in expose/configure event functions?



On Wed, Feb 06, 2002 at 10:09:12AM -0500, Paul Davis wrote:
> >Examples of expose and configure event functions
> >regarding pixmaps seem to return either TRUE or FALSE.
> >
> >What is the meaning of this return value and the purpose?
> 
> *all* signal handlers for signals that have a non-void return type
> must return TRUE or FALSE to indicate whether or not they have
> handled the signal. its up to the handler code to decide what
> "handled" might mean, given the following awareness of what their
> return value will mean:
> 
> if they return TRUE, then generally other handlers that were connected
> later will not be called. if they return FALSE, the other handlers
> will be called.
> 
> the way this all works is a bit muddied in GTK+ 1.2; it appears to be
> much cleaner in GTK+ 1.3/2.0. 
> 
> --p

Thanks for reply.  So it sounds like some signal handlers
are only the first of many functions to handle an event.
(Most of which we don't see or deal with?)
If our function does ALL work then we return TRUE
but if it is only one of many then we return FALSE.
How are we to know if there are other functions GTK+
will want to call for an event?

Thanks again,

Chris



-- 
=======================================================
| Dr. Christian Seberino  || (619) 553-7940  (office) |
| SPAWARSYSCEN 2363       || (619) 553-2836  (fax)    |
| 53560 HULL ST           ||                          |
| SAN DIEGO CA 92152-5001 || seberino spawar navy mil |
=======================================================



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