[Flashcoders] Detect player version that was published

2010-08-24 Thread Todd Dominey
Hi everyone - I have an AS3 component that publishes to either Flash Player 9 or Flash Player 10, and I'm trying to figure out a way to detect (within the component's ActionScript) whether the user published the SWF to 9 or 10 as their target. I realize the SWF is agnostic to the IDE and won't

Re: [Flashcoders] Detect player version that was published

2010-08-24 Thread Henrik Andersson
You could test for a known bug that for backwards compability is still kept in new players. Test if calling gotoAndStop actually instantiates the timeline instances right there or if it is delayed. ___ Flashcoders mailing list

Re: [Flashcoders] Detect player version that was published

2010-08-24 Thread Glen Pike
On 24/08/2010 15:04, Todd Dominey wrote: Hi everyone - I have an AS3 component that publishes to either Flash Player 9 or Flash Player 10, and I'm trying to figure out a way to detect (within the component's ActionScript) whether the user published the SWF to 9 or 10 as their target. I

Re: [Flashcoders] Detect player version that was published

2010-08-24 Thread Anthony Pace
I wasn't going to suggest a known bug, I was just going to suggest looking for features that were included in a revision; yet, I like yours better. On 8/24/2010 10:14 AM, Henrik Andersson wrote: You could test for a known bug that for backwards compability is still kept in new players.

Re: [Flashcoders] Detect player version that was published

2010-08-24 Thread Zeh Fernando
Yep; see loaderInfo.swfVersion. http://www.adobe.com/livedocs/flash/9.0/ActionScriptLangRefV3/flash/display/LoaderInfo.html#swfVersion Or a way for a Flash Player 9 SWF to try and access a Flash Player 10 property of some kind that won't return a compile error in the IDE? Instead of trying

Re: [Flashcoders] Detect player version that was published

2010-08-24 Thread Todd Dominey
Right, not looking for the Flash Player plugin version a user has installed, but rather which runtime the SWF was published to (9 or 10). The root of my dilemma is that Flash's behavior when applying an alpha tween to a Sprite containing a text field using system typefaces isn't consistent when

Re: [Flashcoders] Detect player version that was published

2010-08-24 Thread Glen Pike
On 24/08/2010 15:36, Todd Dominey wrote: Right, not looking for the Flash Player plugin version a user has installed, but rather which runtime the SWF was published to (9 or 10). The root of my dilemma is that Flash's behavior when applying an alpha tween to a Sprite containing a text field

Re: [Flashcoders] Detect player version that was published

2010-08-24 Thread Glen Pike
On 24/08/2010 15:04, Todd Dominey wrote: Hi everyone - I have an AS3 component that publishes to either Flash Player 9 or Flash Player 10, and I'm trying to figure out a way to detect (within the component's ActionScript) whether the user published the SWF to 9 or 10 as their target. I

Re: [Flashcoders] Detect player version that was published

2010-08-24 Thread Todd Dominey
A-ha - I think you're right. For example I tried this: lg_ldr = new Loader(); try { trace(lg_ldr[unloadAndStop]) } catch(e:Error) { trace(error) } With FP9 as the runtime, catch handles it. With FP10 as the runtime, 'function...' is traced. Now I just need to find something a little less

Re: [Flashcoders] Detect player version that was published

2010-08-24 Thread Juan Pablo Califano
Right, not looking for the Flash Player plugin version a user has installed, but rather which runtime the SWF was published to (9 or 10). Then I think you should go with Zeh's suggestion: http://www.adobe.com/livedocs/flash/9.0/ActionScriptLangRefV3/flash/display/LoaderInfo.html#swfVersion