Digital Workshop

Welcome to the Digital Workshop Message Boards
It is currently December 22nd, 2024, 11:10 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: Passing ActionScript into Opus Flex
PostPosted: December 7th, 2006, 11:07 pm 
Offline
Godlike
Godlike

Joined: November 11th, 2004, 1:18 pm
Posts: 1213
Location: New York
Opus: Opus Pro 9.75
OS: Windows 10 Pro 64 bit
System: Core i7, 16G RAM, Nvidia 640GT (desktop), plus Windows 10 and Android tablets
Hi

I've been using Opus Flex to create Flash pubs that play in the mobile Flash Lite 2.1 player on mobile devices/phones. Many features work without additional effort. However, a few commands available for the Flash Lite player, based on a new group of Action Script 2 items called fscommand2, won't work.

Since ActionScript is based on ECMA-262 and often recognizes JavaScript, I'm wondering if there is a way to pass one of these commands either "as is" or by first identifying it as JavaScript.

For example, on mobile devices and phones, there is a default focus rectangle, which will identify the object focused on by adding a yellow border, while it has focus. In ActionScript for the Flash Lite 2 player, there is an fscommand2 that changes the color:

fscommand2("SetFocusRectColor", 255, 0, 0)

which will change the color to red.

While I can not get this to be passed along and to work in an Opus Flex pub, other commands do pass along and work. For example, to turn off or on the focus rectangle feature altogether, a command: _focusrect = false, added to the onshow page script object, will shut it off while having it equal "true" instead will keep it on. So, some commands, entered as script in Opus Flex, are read by the Flash Lite 2 player and some are not.

I'm hoping that a DW team member or Forum colleague can suggest a script addition that can enable the Flash Lite player to read these commands or alternately to add them in Java Script with a preface to get the player to read it as JS.

Maybe this is not possible. If it is, I would appreciate any help.

Kind Regards,

_________________
Stephen


Top
 Profile  
 
 Post subject:
PostPosted: December 9th, 2006, 7:17 am 
Offline

Joined: January 19th, 2005, 7:14 pm
Posts: 20
Location: Bromsgrove, Worcs, UK
Hi Stephen

I would be very suprised if any new AS 2.0 code worked with Opus Flex. I don't use it but I believe it publishes to Flash Player 6. However, there were some undocumented features in AS 1.0 that were later included in AS 2.0, you might get lucky.

FstyleFormat.focusRectOuter AS 1.0 should work on components and buttons in Flash proper.So eg

myStyleFormat.focusRectOuter = 0xRRGGBB might be worth a try.


Regards
Ken


Top
 Profile  
 
 Post subject:
PostPosted: December 9th, 2006, 1:13 pm 
Offline
Godlike
Godlike

Joined: November 11th, 2004, 1:18 pm
Posts: 1213
Location: New York
Opus: Opus Pro 9.75
OS: Windows 10 Pro 64 bit
System: Core i7, 16G RAM, Nvidia 640GT (desktop), plus Windows 10 and Android tablets
Hi Ken

Thanks for your reply. I'll try these out.

The fscommand2 items are designed to support navigation and other needed actions in a Flash Lite player. So a few of these commands are important, liking setting focus when you have multiple text input boxes.

It seems to be "hit or miss," trying different scripts to see if they'll work in runtime when on the mobile device.

Any other scripts to try out would be welcome. I've run out of ideas.

Kind Regards,

_________________
Stephen


Top
 Profile  
 
 Post subject:
PostPosted: December 15th, 2006, 3:57 pm 
Offline
Godlike
Godlike

Joined: November 11th, 2004, 1:18 pm
Posts: 1213
Location: New York
Opus: Opus Pro 9.75
OS: Windows 10 Pro 64 bit
System: Core i7, 16G RAM, Nvidia 640GT (desktop), plus Windows 10 and Android tablets
Hi

An update:

unfortunately, these scripts wouldn't work in Flex to achieve the effects.

I would welcome any additional suggestions about getting ActionScripts fscommand2 to work in runtime Flash created by Opus Flex.

Does anyone know how to use JS to call these ActionScript commands? It's my understanding that there are ways to use JS to summon AS, but the info I've seen online is beyond my comprehension:

http://weblogs.macromedia.com/flashjavascript/

(This JS/AS work-a-round may only apply to browser Flash player plugins, rather than standalone Flash players.)

Kind Regards,

_________________
Stephen


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: Majestic-12 [Bot] and 60 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group