3 Replies Latest reply on Jul 13, 2009 9:28 PM by Rothrock

    How to recognize FLVPlayback Component

    Rothrock Level 5

      Publish to Flash 8 and using the FLVPlayback component as part of a larger elearning course.


      We have a legacy pause button that works by recursively looking through every item on stage and if the item is a movieclip following its children and so on. Something like this (there is more to the whole thing, but this is where the problem is):


      findCurrent = function (obj)
      for (var i in obj) {
        if (typeof (obj[i]) == "movieclip" && obj[i] != obj) {
         if (obj[i]._name == "pauser"{

         var m = obj[i];
         m.frameWas = m._currentFrame;


      The issue is that when using the FLVPlayback component the 256 recursions limit is reached. I'm guessing that the video part contains a reference to playback controls skin and the playback controls skin contains a reference to the video part and the recursion just goes round and round till it hits the limit and then all actionscript is disabled for the rest of the file.


      I thought of adding a counter, and that is probabaly a good idea, but I was wondering if there is anyway to identify that I've hit a video player and stop following it?


      Obviously the topeof(myVideoPlayer) is coming back as "movieclip" or I wouldn't be getting this problem. I don't think there is a getQualifiedName for AS2, right? I looked at the properties and couldn't find one that said, "clearlyVideoPlayer."


      So does anybody else have any suggestions?