my interests and experiences
RSS icon Email icon Home icon
  • flash seekbar indicator won’t go away

    Posted on February 12th, 2009 whodeee No comments

    PROBLEM: The Flash seekbar indicator is still on screen when you navigate to a different frame that doesn’t even have the seekBar

    I came across this issue when I wanted to add just the seekbar to the flv component and not have the entire skin. I will use my chapterTest flv from an earlier post for the sake of simplicity. Here is a screenshot of the interface with the flv and seekbar

    seekbar interface

    seekbar interface


    and here is a screenshot of the interface on another frame after the flv played
    seekbar with indicator

    seekbar with indicator


    NOTE:The indicator is still there in the lower right.

    SOLUTION:The very simple way around this problem is to actually put the seekBar inside a movieclip and reference it there – that’s it!

    So my actionscript originally looked like this:import mx.video.*;
    //flv playback component instance name=flv
    //seekBar component instance name=seeker
    flv.seekBar = seeker;
    var listenerObject:Object = new Object();
    listenerObject.complete = function(eventObject:Object):Void {
    gotoAndPlay("end");
    };
    flv.addEventListener("complete", listenerObject);

    and changed to this:import mx.video.*;
    //flv playback component instance name=flv
    //seekBar component instance name=seeker
    //place seeker inside movieclip instance named seeker_mc
    flv.seekBar = seeker_mc.seeker;
    var listenerObject:Object = new Object();
    listenerObject.complete = function(eventObject:Object):Void {
    gotoAndPlay("end");
    };
    flv.addEventListener("complete", listenerObject);

    Leave a reply