Is this in the IDE? If so, you need to turn off keyboard shortcuts

On Thu, Jan 22, 2009 at 10:27 AM, Mendelsohn, Michael <
michael.mendels...@fmglobal.com> wrote:

> Hi list...
>
> I have a sprite that should fire an event either when it's clicked, or
> when it has focus and the spacebar or the enter key is pressed.  The
> mouse click and the spacebar keyUp events (when the sprite has focus)
> work fine, but the enter key won't fire the event.  Here's my if
> statement.  Am I missing something?
>
> private function myEvent(e:*):void {
>        if(e.type =="keyUp"){
>                trace(e.keyCode);
>                // traces 32 for spacebar but nothing for enter key
>        }
>        if
> ((e.type=="mouseUp")||((e.type=="keyUp")&&(e.keyCode==32))||((e.type=="k
> eyUp")&&(e.keyCode==Keyboard.ENTER))) {
>
> thanks,
> - Michael M.
>
> _______________________________________________
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>



-- 
http://ericd.net
Interactive design and development
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to