2 Replies Latest reply on Oct 19, 2007 9:00 AM by HonSwe

    Interfering Movie Clips

    HonSwe
      Hello Community,

      I can't believe that I have only run into this (what should be a relatively simple) problem after so many successful AS2 projects.

      Anywho, here's the skinny: I have a video screen that I feed vids to with the NetStream Class that is the same size as my published SWF file. In other words, the movie that streams to this screen is the same size as the SWF file, so there is no room to have any controls (Pause/Play/Scrubber/LoadProgress/etc...) sitting under the video screen -- the only place for these contols would be over the streaming video. Can't have that, of course, since it would interefere with (partially cover up) the movie.

      Not to worry though, right? I want to take Apple QuickTime's approach to a solution for fading in these controls whenever the user mouses over the video playing area (in this case my entire SWF stage). Similar to the FLVPlayback component, too...

      So, I have set it up where if the user mouses over the stage of the SWF (actually a hidden MC with the same dimensions as the stage), my playback controls panel movieclip (vidControlPanel_mc) fades in on a layer above the hidden fade in triggering MC. All this works, until I try to do things within the vidControlPanel_mc movieclip. Flashplayer is getting confused as to which events I am trying to access, those within the hidden "controls activator" or those buttons/scrubber/etc... elements within the (on the next higher layer) vidControlPanel_mc. The "hit areas" of both of these MC's has some overlap.

      Any thoughts on the best way to solve my problem?

      Any input would be appreciated.

      -john
        • 1. Re: Interfering Movie Clips
          ChrisElmes
          "Getting Confused" hmmm, It is fair to say the flash player is responding to the events it sees happening!

          E.g
          if the hidden button is the full area and the rollover says "fade in the controls" and the rollout says "fade out the controls" when you roll from this hidden button onto the controls (thats technically a rollout from the hidden button followed by a rollover of the controls) the controls will fade out first before then trying to figure out what it was supposed to do on the controls rollover.

          Is that the sort of "confusion" your flash player is having?

          If so, you could try changing the hidden button to "track as menu" in the properties panel

          or you could remove the rollover from the hidden button and perhaps put the code on the rollout of the controls?

          basically you just have to figure out the order of events that are being triggered and account for them.

          you could for instance on the rollout of the hidden button, test the mouse x and y and if they are over the controls do nothing, if not fade out the controls.

          hope that helps or at least gives you a starting point

          Chris
          • 2. Re: Interfering Movie Clips
            HonSwe Level 1
            ChrisElmes,

            Thanks for your reply. I've tried all of your suggestions to no avail. Some got me further than others. Using a mouse event listener got me the closest, but even with that technique I had instabilities.

            I think that I am going to abandon this line of thought and just place a small button in the corner that shows and expands the control panel.

            Thanks for your input.

            -john