Determine which control is being focused on in focusOut message?

David Bovill david at openpartnership.net
Thu Jan 31 12:45:11 EST 2008


On 31/01/2008, Trevor DeVore <lists at mangomultimedia.com> wrote:
>
> On Jan 31, 2008, at 11:58 AM, David Bovill wrote:
>
> > True - least that's not against Relativity then... so won't wait with
> > messages work? Though I guess it is equivalent in most ways to send
> > in...
> > and what limitations are you tryin to get around with send in?
>
> In the focusOut handler I call another handler (CheckFocusedObject)
> using send in time. CheckFocusedObject then determines if focus is
> still within a particular group. If focus is still in the group then a
> UI toolbar remains visible. If focus has left the group then the UI
> toolbar is hidden.
>
> The UI is basically responding to changes in the focusedObject. I feel
> that having the code that turns the UI toolbar on/off within the group
> is much cleaner than trying to watch for focus within the group at the
> card or frontscript level. I am just hoping to remove any need for
> send in time, wait with messages, etc.


OK - had a go Trevor, but I can't see any way around it - the focusout is
sent before the focus in - so you'll have to use send in to effectively go
forwards in time?



More information about the use-livecode mailing list