What I'm making is a simple tool similar to a flowchart, where 
people can drag objects onto the canvas, then drag arrows too, to 
connect the first objects. I got it so that they could rotate the 
arrows using the cursor keys on the keyboard, but as soon as the 
browser is deactivated, this doesn't work anymore when you come 
back. 

I guess I have to try another approach. 

Isn't there a hope that people might program games in Flex? If so, 
I'd think that keyboard support would be essential, at least for 
some games.

Thanks,
Jack

--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> graphical things haven't been the main focus of Flex, but system
> security is tantamount and the player doesn't want to allow you to 
sniff
> keystrokes from other applications so when you lose activation 
lots of
> things may stop working.  I've marked this to try in a simple 
testcase,
> but it may be a while before we get around to it.
>  
> -Alex
> 
> ________________________________
> 
> From: flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] On
> Behalf Of jack_freud
> Sent: Thursday, May 10, 2007 10:59 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: keypress stops working after browser 
loses
> focus
> 
> 
> 
> Not sure I understand. I'm clicking in it to make sure it has 
focus. 
> In fact I tried adding activate and deactivate handlers for the 
> container, and in the activate I add the keydown listener. Tracing 
> shows that the activate event fired, but the keydown event never 
> shows up again.
> 
> I'm surprised this doesn't work... how can you use flex to do 
> graphical things with the keyboard if you can't listen to it?
> 
> Thanks for responding,
> Jack
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%
40yahoogroups.com>
> , "Alex Harui" <aharui@> wrote:
> >
> > I don't know if we can solve that one, especially in all 
browsers.
> > Usually when the browser becomes active the player instance still
> > doesn't have focus. And once you give it focus, it may have 
> forgotten
> > its repeat state. Keyboard related stuff is a topic of 
discussion 
> at
> > Adobe these days.
> > 
> > -Alex
> > 
> > ________________________________
> > 
> > From: flexcoders@yahoogroups.com <mailto:flexcoders%
40yahoogroups.com>
> 
> [mailto:flexcoders@yahoogroups.com <mailto:flexcoders%
40yahoogroups.com>
> ] On
> > Behalf Of jack_freud
> > Sent: Thursday, May 10, 2007 8:26 AM
> > To: flexcoders@yahoogroups.com <mailto:flexcoders%
40yahoogroups.com> 
> > Subject: [flexcoders] Re: keypress stops working after browser 
> loses
> > focus
> > 
> > 
> > 
> > For what it's worth, I meant keydown.
> > 
> > Still stuck!
> > 
> > --- In flexcoders@yahoogroups.com
> <mailto:flexcoders%40yahoogroups.com>  <mailto:flexcoders%
> 40yahoogroups.com>
> > , "jack_freud" <jack_web@> wrote:
> > >
> > > Hi,
> > > 
> > > I'm using keypress events to rotate a sprite on a canvas. It 
> works 
> > > fine until you click on some other window on your desktop, 
then 
> come 
> > > back to the browser. Then you can click on things with no 
> problem 
> > but 
> > > the keypress event stops firing.
> > > 
> > > I'm listening for the event in the container, as I couldn't 
find 
> a 
> > way 
> > > to give my sprite component focus itself.
> > > 
> > > Any help would be much appreciated!
> > > 
> > > Jack
> > >
> >
>


Reply via email to