Samsung Internet@TV Flash Gets Focused

Recently while working on a Stagecraft based project for RCDb I ran into a little snag that had I not quickly RTFM’ed I might have been stuck on for a long time. Now when I say quickly I mean about after an hour of trying every trick in the book including praying, posting to Samsung Dev forum (waited 3 days with no response), and every combination of using the .focus() method I could think of…

The manual states that HTMLObjectElement in fact does *not* have a .focus() method. Well, this does not jive with the fact that whatever browser they are using in the “Emulator” does in fact support the .focus() method. Hence why maybe I did not go to the manual right away. “It works in the emulator” (It works on my machine echoing as scene slowly fades to black then a vision

of Eddie Vedder glows like the Jesus thing you stare at, image below).

Well, in the end, you need to actually do two things to make it work in both places.

Emulator: Does in fact support .focus() for the HTMLObjectElement, so just call it at some point after your onLoad method.

TV: You have to set the tabIndex of the HTMLObjectElement to 0, and then call focus on the window.

tabIndex = 0;

At least that is what works for me… Now, if you want to set leading on a dynamic text field, post a comment and send your email, that one is going to cost you… 🙂