Copy link to clipboard
Copied
Hi.
I´m trying to catch KEY_UP event if I press ENTER, without clicking on stage.
I´ve already disabled keyboard shorcuts for flash player, and added stage.focus = stage.
Not succeeding.
It only works if I click on stage.
It seems that for the other keys the KEY_UP works.
Any help?
Copy link to clipboard
Copied
are you testing in your browser or, if in the test environment, did you disable keyboard shortcuts?
Copy link to clipboard
Copied
Yes I have disabled.
KEY_DOWN works for key ENTER, without click on stage, but KEY_UP doesn´t.
Copy link to clipboard
Copied
you're correct.
you won't even be able to capture your keydown's if you're creating a browser based app unless you use javascript to assign focus to your flash.
Copy link to clipboard
Copied
What if I wanted to add focus (as clicking on stage) for a projector (aka EXE file)
Copy link to clipboard
Copied
test and let us know.
Copy link to clipboard
Copied
Works for projector files, no need to click on stage.
How do I set flash focus for Chrome?
I know that for IE is document.getElementById("movieID").focus();
What is needed to set flash focus on Chrome?
Copy link to clipboard
Copied
use javascript to assign focus in a browser. this is from an adobe kb article:
To the <BODY> tag, add an onLoad handler that gives focus to the Flash movie, as shown below: <body onLoad="window.document.movieID.focus();"> Make sure that movieID in the onLoad handler matches the name given to the OBJECT tag used to embed the Flash movie, as shown below. <object classid="..." codebase="...." width=550 height=400 name="movieID"> You can give any name to the OBJECT tag as long as it doesn't contain any spaces or other special characters.
Copy link to clipboard
Copied
Yes, but that is used for Internet Explorer.
That doesn´t work on Chrome, and I think for Firefox too.
What is used for Chrome?
I´ve tried to use ExternalInterface and LoaderInfo in addition to some js.
It only gives flash focus I think, doesn´t seems to give keyboard focus.
I have an input text field on my swf.
The cursor blinks inside the text input, but I can´t write (type) anything inside the input text.
Copy link to clipboard
Copied
I have the same problem and it would be awesome when someone could give a solution for any browser.
Is there someone with a working solution?????????