Cześć ,

Mam taki problem.

Mam tutaj actionscripta który wyświetla na video przyciski , jednak nie działają mi przyciski do odtwarzania , stopowania , i ściszania.

Możecie pomóc?

Podsyłam poniżej kod

package 
{
    import flash.display.*;
    import flash.text.TextField;
    import flash.text.TextFormat;
    import flash.text.TextFieldAutoSize;
    import flash.net.NetConnection;
    import flash.net.NetStream;
    import flash.display.MovieClip;
    import flash.media.Video;
    import flash.events.*;
    import flash.net.*;

    public class FakeAd extends Sprite
    {
        private var tw:twitter;
        private var fb:facebook;
        private var im:images;
        public var nc:NetConnection;
        public var ns:NetStream;
        private var video:Video;

        public function FakeAd(lineColor:Number, fillColor:Number, label:String)
        {
            function asyncErrorHandler(event:AsyncErrorEvent):void
            {
            }
 
            nc = new NetConnection();
            nc.connect(null);
            ns = new NetStream(nc);
            //ns.addEventListener(AsyncErrorEvent.ASYNC_ERROR, this.asyncErrorHandler);
            ns.play("http://traffic.idmnet.pl/21057/lekarzeIV.mp4");
            video = new Video(640,360);
            video.attachNetStream(ns);
            video.smoothing = true;
            addChild(video);
            ns.resume();
 
            fb = new facebook();
            this.addChild(fb);
            //fb.x = 380;
            fb.y = 10;

            tw = new twitter();
            this.addChild(tw);
            //tw.x = 80;
            tw.y = 40;
 
            im = new images();
            this.addChild(im);
            im.y = 60;
 
            fb.addEventListener(MouseEvent.CLICK, facebookClicke);
            tw.addEventListener(MouseEvent.CLICK, twitterClicke);

            function facebookClicke(e:MouseEvent):void
            {
                navigateToURL(new URLRequest("https://pl-pl.facebook.com/"));
            }

            function twitterClicke(e:MouseEvent):void
            {
                navigateToURL(new URLRequest("https://twitter.com/"));
            }

            this.tw.x =40;
            this.fb.x =40;
            this.im.x =40;
            this.tw.y =  150;
        }

        public function iPause() : void
        {
            ns.pause();
            return;
        }
  
        public function iResume() : void
        {
            ns.resume();
            return;
        }
    }
}

dodanie znacznika <code class="actionscript"> i sformatowanie kodu - Furious Programming