PDA

View Full Version : FLVPlayback issues with dynamically applied skin


tathamoddie
10-30-2007, 12:50 AM
Hi everyone.

I have a blank SWF file (MoviePlayer.swf) with the following ActionScript in it:


import mx.video.*;

Stage.scaleMode = "noScale";
Stage.align = "TL";

ap = (ap == 'true');

this.attachMovie("FLVPlayback", "playbackControl", 10, {width:_root.w, height:_root.h, x:0, y:0});
playbackControl.skin = skinPath;
playbackControl.autoPlay = ap;
playbackControl.autoSize = true;
playbackControl.contentPath = videoPath;


Basically I just place this generic SWF on the page, then supply links to the skin file and the FLV file through flashVars.

It's all working perfectly except for one very strange bug ... The play/pause button doesn't work after seeking.

If you play the video, the seek handle moves as expected. You can pause, and restart the video fine. As soon as you actually grab the seek handle and move it though the button forgets what to do.

Now, initially I thought this was an issue with our custom skin, however I'm getting the same issue with the built in skins. Loading the same skins through the Flash interface (place an FLVPlayback component on the page and configure it in the GUI) works fine. The problem only occurs when I dynamically load the skin using the code above.

I'd really appreciate any ideas on either how to fix this, or how best to debug it. Any feedback on my general approach would be greatly appreciated too.

Thanks! :)

pan69
10-30-2007, 01:22 AM
Hi and welcome to ActionScript.org,

I've never had that problem before and I don't know if this fixes your issues. You might want to try and update (http://www.adobe.com/support/flash/downloads.html) your FLVPlayBack component. Just search the page for FLVPlayBack.

tathamoddie
10-30-2007, 01:42 AM
Hi pan69 ... thanks for the prompt reply.

I'm working in Flash CS3, publishing the file for Flash 7 with ActionScript 2.

To the best of my knowledge, this should mean I have the latest component - right?

atomic
10-30-2007, 02:29 AM
What if you re-attach the playbackControl after release of the seek handle?