chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] Callback question


From: felix winkelmann
Subject: Re: [Chicken-users] Callback question
Date: Sat, 1 Sep 2007 17:46:29 +0200

On 8/25/07, William Ramsay <address@hidden> wrote:
> Hi,
>
> When handling a callback with define-external, how do you get it to fall
> through.
> In other words, I'm watching for a Return keystroke in a dialog box.
> If the user
> presses a letter key, the key should be passed on to normal data entry.
> However.
> if a Return is pressed, I want my handler to handle it.    It seems that
> to do this
> I have to pick up all keystrokes, test for Return, and pass the code on
> if it is not
> a Return.   Problem is I have no idea how to 'pass it on'.
>
> Any ideas?
>

That depends on the event handling model of the gui toolkit you
use. Often, event-handlers return a boolean indicating whether
the handler processed the event or not (and thus other handlers
should get a chance to run). In Qt, for example you have explicit
"accept()" and "reject()" member functions for accepting the event
or to reject it and let other event handlers (possibly default handlers)
have a go.


cheers,
felix




reply via email to

[Prev in Thread] Current Thread [Next in Thread]