
 

function get_mediainfo(mediainfoIndex) {
	var jetzt = new Date();
	var strClientLocalTime = formatDate(jetzt,"yyyy-MM-d_HH:mm:ss");

	
    switch (mediainfoIndex) {        
        case 0:  //mediaUrl": "video/2500_Volvo_Spot.wmv "mediaUrl": "../test/player_asx/asxgen.php?MandantID=2&LocalTime="+strClientLocalTime+"&channelID=1&typ=.wmv&SpeedID=3",
            return  { "mediaUrl": "../../test/player_asx/asxgen.php?MandantID=2&LocalTime="+strClientLocalTime+"&channelID=1&typ=.wmv&SpeedID=3",
                      "placeholderImage": "",
                      "chapters": [               
                                  ] };                                                                
        case 1:
            return  { "mediaUrl": "../../test/player_asx/asxgen.php?MandantID=2&LocalTime="+strClientLocalTime+"&channelID=1&typ=.wmv&SpeedID=4",
                      "placeholderImage": "",
                      "chapters": [               
                                  ] };                                                                
        case 2:
            return  { "mediaUrl": "../../test/player_asx/asxgen.php?MandantID=2&LocalTime="+strClientLocalTime+"&channelID=1&typ=.wmv&SpeedID=5",
                      "placeholderImage": "",
                      "chapters": [               
                                  ] };                                                                
                          
        default:
             throw Error.invalidOperation("No such mediainfo");
     }

}


var PlayingCounter = 0;
function media_state_changed(sender, args)
		{
			
//			var mediaStateTextBlock = 
//			sender.findName("mediaStateTextBlock");
			var media = sender.findName("VideoWindow");
//			mediaStateTextBlock.Text = media.CurrentState;
//setze_bewertung(-1);
			if (media.CurrentState == 'Playing') {
				PlayingCounter++;

				
				if (PlayingCounter == 1) {
				 //alert("_onmedia_state_changed: "+media.CurrentState+"  FIlmID:"+SLActualFilmID);
				 //setTimeout( "auslesen_bewertung(-1);", 2000);
				 // wird jetzt im dbinterface gemacht    
				 //setTimeout( "setze_bewertung(-1);", 2000);
				 addKlickActive = false;
				 addKlicked = false;
				 // Hier wird automatisch der EPG angepasst, sobald im Live Tab der beitrag wechselt
				 if (FlagLiveRunning) setTimeout( "EPGrefresh()", 2000);  	//alert("refresh");
				 //setTimeout( "PlayingCounter = 0;", 10000);

				}
			}
		}
	

//// Hintergrundaufruf eines Zaehlers
//function getHttpRequest(url) {
//   
//    var xmlhttp = null;
//    // Mozilla
//    if (window.XMLHttpRequest) {
//        xmlhttp = new XMLHttpRequest();
//    }
//    // IE
//    else if (window.ActiveXObject) {
//        xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
//    }
//   
//    xmlhttp.open("GET", url, true);
//    xmlhttp.onreadystatechange = function() {
//        if(xmlhttp.readyState != 4) {
//            $('addpixelchen').innerHTML = ' ';
//        }
//        if(xmlhttp.readyState == 4 && xmlhttp.status == 200) {
//            $('addpixelchen').innerHTML = xmlhttp.responseText;
//        }
//    }
//    xmlhttp.send(null);
//} 
//
//function onMarkerReached(sender, markerEventArgs)
//		{
//		var text = markerEventArgs.marker.text;
//		//var theDiv = document.getElementById("output");
//	   var ObjaddIMG_click_canvas = sender.findName("addIMG_click_canvas");
////		alert("22"+text.toUpperCase());	
//		   switch (text.toUpperCase())
//		   {
//			  case ("ADDIMG_START"):
////alert("22"+text.toUpperCase()+"   addKlickActive:"+addKlickActive);	
//			  		addKlickActive = true;
//					ObjaddIMG_click_canvas.Cursor="Hand";  // Der Cursor wird über der unsichtbare Fläche (über dem Player) mit einer hand versehen.
//					// Beim Klicken auf dieser Fläche wird eine URL aktiv
//					KlickStartUrl = "http://ad.doubleclick.net/clk;197574011;18247828;o?http://clk.atdmt.com/MOE/go/spdssvld0100000176moe/direct/01/";
//					// http://view.atdmt.com/MOE/view/spdssvld0100000176moe/direct/01/Bei Bedarf wird hier noch ein Zaehler aufgerufen, der die Filmaufrufe zählt
//					ZaehlUrl = "http://view.atdmt.com/MOE/view/spdssvld0100000176moe/direct/01/";
//					//ZaehlUrl = "http://www.deltv.org/deltv/adserver/mailcounter.php";
//					//window.open(ZaehlUrl);
//					ReqResult = getHttpRequest(ZaehlUrl); // Zaehler durchlaufen lassen.
//					//ReqResult = getHttpRequest("http://www.deltv.org/deltv/adserver/mailcounter.php"); // Zaehler durchlaufen lassen.
//
//					//Loader();					
//
//					
//				  alert("addKlickActive = "+ addKlickActive);
//				  break;
//			  case ("ADDIMG_END"):
//			  	  addKlickActive = false;
//				  ObjaddIMG_click_canvas.Cursor="Arrow";
//				  alert("addKlickActive = "+ addKlickActive);			 
//				  break;
//			  default:
//				  		  
//				  alert("addKlickActive Derfault: "+ addKlickActive+"-->Text:"+text);			 
//				  break;
//		   }
//	//		alert("-11-"+markerEventArgs.marker.text +"-----"+markerEventArgs.marker.type  +"-----"+ markerEventArgs.marker.text);
//	//			var mediaStateTextBlock = 
//	//			sender.findName("mediaStateTextBlock");
//
//
//	}
//	





function StartWithParent(parentId, appId) {
    new StartPlayer_0(parentId);
}
//width:'1024', height:'768'
function StartPlayer_0(parentId) {
    this._hostname = "SilverlightControl";
    Silverlight.createObjectEx( {   	source: 'player.xaml', 
                                        parentElement: $get(parentId ||"divPlayer_0"), 
                                        id:this._hostname, 
                                        properties:{ width:'100%', height:'100%', version:'2.0', background:"#1E1E1E", isWindowless:'false' }, 
                                        events:{ onLoad:Function.createDelegate(this, this._handleLoad) } } );
                                        this._currentMediainfo = 0;
                                        //alert("Magazin Begin" + Magrefresh());
                                        //this.Magazinslide_in.begin();
                                        //Magrefresh();
                                          
}



//None	 Specifies that no scaling is performed.
//	Zoom	Specifies that scaling is performed to size the Silverlight content proportionally to fill the host area.
//	Stretch	Specifies that scaling is performed to fill the host area horizontally and vertically.



StartPlayer_0.prototype = {
    _handleLoad: function(plugIn, userContext, rootElement) {
        this._player = $create(ExtendedPlayer.Player,
                                  { // properties
                                      autoPlay: true,
                                      volume: 0.5,
                                      muted: false,
                                      ScaleMode: "Stretch"
                                  },
                                  { // event handlers ,, ScaleMode="None|Zoom|Stretch"
                                      mediaEnded: Function.createDelegate(this, this._onMediaEnded),
                                      mediaFailed: Function.createDelegate(this, this._onMediaFailed)
                                      //media_state_changed: Function.createDelegate(this, this._onmedia_state_changed)

                                  },
                                  null, $get(this._hostname));
        // Silverligth host zuweisen zur späteren Benutzung  
        this.host = rootElement.getHost();
        this.content = this.host.content;

        //alert(this.content);

        this.Emupdsl500 = plugIn.Content.findName('niedrig');
        this.Emupdsl500.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._dsl500));
        this.Emupdsl500.addEventListener("MouseEnter", Function.createDelegate(this, this._dsl500a));
        this.Emupdsl500.addEventListener("MouseLeave", Function.createDelegate(this, this._dsl500i));
        if (SLActualSpeed == 3) { this.Emupdsl500.Opacity = 1; }

        this.Emupdsl1500 = plugIn.Content.findName('hoch');
        this.Emupdsl1500.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._dsl1500));
        this.Emupdsl1500.addEventListener("MouseEnter", Function.createDelegate(this, this._dsl1500a));
        this.Emupdsl1500.addEventListener("MouseLeave", Function.createDelegate(this, this._dsl1500i));
        if (SLActualSpeed == 4) { this.Emupdsl1500.Opacity = 1; }

        this.Emupdsl2500 = plugIn.Content.findName('maximal');
        this.Emupdsl2500.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._dsl2500));
        this.Emupdsl2500.addEventListener("MouseEnter", Function.createDelegate(this, this._dsl2500a));
        this.Emupdsl2500.addEventListener("MouseLeave", Function.createDelegate(this, this._dsl2500i));
        if (SLActualSpeed == 5) { this.Emupdsl2500.Opacity = 1; }


        // Objekte erfassen die im JS benötigt werden.
        this.MuteOnSymbol = this.content.findName("MuteOnSymbol");
        this.MuteOnSymbol.Opacity = 0.0;
        this.MuteOffSymbol = this.content.findName("MuteOffSymbol");
        this.MuteOffSymbol.Opacity = 0.0;


        this.SchlossSymbol = this.content.findName("schloss");
        this.SchlossSymbol.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_ExterneSeite));

        this.ImpressumSymbol = this.content.findName("Impressum");
        this.ImpressumSymbol.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Impressum));

        this.KontaktSymbol = this.content.findName("Kontakt");
        this.KontaktSymbol.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Kontakt));

        this.Topfilter_1 = this.content.findName("topfilter_1");
        this.Topfilter_1.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._VOD_refresh_filter_1));
        this.Topfilter_2 = this.content.findName("topfilter_2");
        this.Topfilter_2.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._VOD_refresh_filter_2));
        this.Topfilter_3 = this.content.findName("topfilter_3");
        this.Topfilter_3.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._VOD_refresh_filter_3));

        this.Topfilter_4 = this.content.findName("topfilter_4");
        this.Topfilter_4.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._VOD_refresh_filter_4));

        this.Topfilter_5 = this.content.findName("topfilter_5");
        this.Topfilter_5.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._VOD_refresh_filter_5));
        this.Topfilter_6 = this.content.findName("topfilter_6");
        this.Topfilter_6.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._VOD_refresh_filter_6));
        this.Topfilter_7 = this.content.findName("topfilter_7");
        this.Topfilter_7.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._VOD_refresh_filter_7));

        this.Topfilter_8 = this.content.findName("topfilter_8");
        this.Topfilter_8.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._VOD_refresh_filter_8));


        //		this.SlideInLive = this.content.findName("LiveVideo");		

        this.TellAFriend = this.content.findName("tellafriend");
        this.TelafriendFlyMouse = this.content.findName("TellafriendFlyMouse");
        this.TellAFriend.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._TellAFriend_ExterneSeite));
        this.TellAFriend.addEventListener("MouseEnter", Function.createDelegate(this, this._TellAFriendMouseEnter));
        this.TellAFriend.addEventListener("MouseLeave", Function.createDelegate(this, this._TellAFriendMouseLeave));

        this.info = this.content.findName("info");
        this.infoFlyMouse = this.content.findName("InfoFlyMouse");

        this.info.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._info));
        this.info.addEventListener("MouseEnter", Function.createDelegate(this, this._infoMouseEnter));
        this.info.addEventListener("MouseLeave", Function.createDelegate(this, this._infoMouseLeave));


        this.StoryBewertung = this.content.findName("votedfly_inout");

        this.touchVoting = this.content.findName("Wertung");

        this.touchVoting.addEventListener("MouseEnter", Function.createDelegate(this, this._touchVotingEnter));
        this.touchVoting.addEventListener("MouseLeave", Function.createDelegate(this, this._touchVotingLeave));

        this.touchImpressum = this.content.findName("Impressum");

        this.touchImpressum.addEventListener("MouseEnter", Function.createDelegate(this, this._touchImpressumEnter));
        this.touchImpressum.addEventListener("MouseLeave", Function.createDelegate(this, this._touchImpressumLeave));

        this.touchKontakt = this.content.findName("Kontakt");

        this.touchKontakt.addEventListener("MouseEnter", Function.createDelegate(this, this._touchKontaktEnter));
        this.touchKontakt.addEventListener("MouseLeave", Function.createDelegate(this, this._touchKontaktLeave));




        this.Bewertung_votedtext = this.content.findName("votedtext");

        this.Bewertung_spot_1 = this.content.findName("spot_1");
        this.Bewertung_spot_1_c = this.content.findName("spot1_c");

        this.Bewertung_spot_1.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Bewertung_spot_1));

        this.Bewertung_spot_2 = this.content.findName("spot_2");
        this.Bewertung_spot_2_c = this.content.findName("spot2_c");
        this.Bewertung_spot_2.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Bewertung_spot_2));

        this.Bewertung_spot_3 = this.content.findName("spot_3");
        this.Bewertung_spot_3_c = this.content.findName("spot3_c");
        this.Bewertung_spot_3.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Bewertung_spot_3));

        this.Bewertung_spot_4 = this.content.findName("spot_4");
        this.Bewertung_spot_4_c = this.content.findName("spot4_c");
        this.Bewertung_spot_4.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Bewertung_spot_4));

        this.Bewertung_spot_5 = this.content.findName("spot_5");
        this.Bewertung_spot_5_c = this.content.findName("spot5_c");
        this.Bewertung_spot_5.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Bewertung_spot_5));



        // Buttons 



        this.SlideInLive = this.content.findName("touchLive");
        this.SlideInLive.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._SlideInLive));

        this.SlideInMagazin = this.content.findName("CanvasText_magazin");
        this.SlideInMagazin.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._SlideInMagazin));

        this.VideoOnDemand2 = this.content.findName("canvastextVoD");
        this.VideoOnDemand2.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._SlideInVoD));
        this.VideoOnDemand = this.content.findName("CanvastextVoD2");
        this.VideoOnDemand.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._SlideInVoD));

        this.FadeInExtended = this.content.findName("touchExtended");
        this.FadeInExtended.addEventListener("MouseEnter", Function.createDelegate(this, this._FadeInExtended));

        this.FadeOutExtended = this.content.findName("touchExtended");
        this.FadeOutExtended.addEventListener("MouseLeave", Function.createDelegate(this, this._FadeOutExtended));

        this.StoryOutExtended = this.content.findName("extended_out");
        this.StoryInExtended = this.content.findName("extended_in");


        //// Events erzeugen um nach Klick auf Magazinbild den Film zu starten:
        this.MagImage = this.content.findName("MagImage");
        this.MagImage.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Magazin_Film));


        //----------		
        this.ButtChapterArea_ScrollNext = this.content.findName("ChapterArea_ScrollNext");
        this.ButtChapterArea_ScrollNext.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._ButtChapterArea_ScrollNext));

        this.ButtChapterArea_ScrollPrevious = this.content.findName("ChapterArea_ScrollPrevious");
        this.ButtChapterArea_ScrollPrevious.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._ButtChapterArea_ScrollPrevious));
        //--------
        this.ButtChapterArea_ScrollNext_vod = this.content.findName("ChapterArea_ScrollNext_vod");
        this.ButtChapterArea_ScrollNext_vod.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._ButtChapterArea_ScrollNext_vod));

        this.ButtChapterArea_ScrollPrevious_vod = this.content.findName("ChapterArea_ScrollPrevious_vod");
        this.ButtChapterArea_ScrollPrevious_vod.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._ButtChapterArea_ScrollPrevious_vod));
        //----------
        this.ButtChapterArea_ScrollNext_mag = this.content.findName("ChapterArea_ScrollNext_mag");
        this.ButtChapterArea_ScrollNext_mag.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._ButtChapterArea_ScrollNext_mag));

        this.ButtChapterArea_ScrollPrevious_vod = this.content.findName("ChapterArea_ScrollPrevious_mag");
        this.ButtChapterArea_ScrollPrevious_vod.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._ButtChapterArea_ScrollPrevious_mag));
        //----------
        this.fly_0 = this.content.findName("fly_0");
        //		this.vbildblende_0 = this.content.findName("vorschaubild_0");
        this.fly_0.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_0 = this.content.findName("vorschaubild_0");
        this.Storyfly_0_MouseEnter = this.content.findName("fly_0_MouseEnter");
        this.fly_0.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_0_MouseEnter));
        this.Storyfly_0_MouseLeave = this.content.findName("fly_0_MouseLeave");
        this.fly_0.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_0_MouseLeave));

        this.fly_1 = this.content.findName("fly_1");
        //		this.vbildblende_1 = this.content.findName("vorschaubild_1");
        this.fly_1.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_1 = this.content.findName("vorschaubild_1");
        this.Storyfly_1_MouseEnter = this.content.findName("fly_1_MouseEnter");
        this.fly_1.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_1_MouseEnter));
        this.Storyfly_1_MouseLeave = this.content.findName("fly_1_MouseLeave");
        this.fly_1.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_1_MouseLeave));

        this.fly_2 = this.content.findName("fly_2");
        //		this.vbildblende_2 = this.content.findName("vorschaubild_2");
        this.fly_2.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_2 = this.content.findName("vorschaubild_2");
        this.Storyfly_2_MouseEnter = this.content.findName("fly_2_MouseEnter");
        this.fly_2.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_2_MouseEnter));
        this.Storyfly_2_MouseLeave = this.content.findName("fly_2_MouseLeave");
        this.fly_2.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_2_MouseLeave));

        this.fly_3 = this.content.findName("fly_3");
        this.fly_3.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_3 = this.content.findName("vorschaubild_3");
        this.Storyfly_3_MouseEnter = this.content.findName("fly_3_MouseEnter");
        this.fly_3.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_3_MouseEnter));
        this.Storyfly_3_MouseLeave = this.content.findName("fly_3_MouseLeave");
        this.fly_3.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_3_MouseLeave));

        this.fly_4 = this.content.findName("fly_4");
        this.fly_4.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_4 = this.content.findName("vorschaubild_4");
        this.Storyfly_4_MouseEnter = this.content.findName("fly_4_MouseEnter");
        this.fly_4.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_4_MouseEnter));
        this.Storyfly_4_MouseLeave = this.content.findName("fly_4_MouseLeave");
        this.fly_4.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_4_MouseLeave));

        this.fly_5 = this.content.findName("fly_5");
        this.fly_5.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_5 = this.content.findName("vorschaubild_5");
        this.Storyfly_5_MouseEnter = this.content.findName("fly_5_MouseEnter");
        this.fly_5.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_5_MouseEnter));
        this.Storyfly_5_MouseLeave = this.content.findName("fly_5_MouseLeave");
        this.fly_5.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_5_MouseLeave));

        this.fly_6 = this.content.findName("fly_6");
        this.fly_6.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_6 = this.content.findName("vorschaubild_6");
        this.Storyfly_6_MouseEnter = this.content.findName("fly_6_MouseEnter");
        this.fly_6.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_6_MouseEnter));
        this.Storyfly_6_MouseLeave = this.content.findName("fly_6_MouseLeave");
        this.fly_6.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_6_MouseLeave));

        this.fly_7 = this.content.findName("fly_7");
        this.fly_7.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_7 = this.content.findName("vorschaubild_7");
        this.Storyfly_7_MouseEnter = this.content.findName("fly_7_MouseEnter");
        this.fly_7.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_7_MouseEnter));
        this.Storyfly_7_MouseLeave = this.content.findName("fly_7_MouseLeave");
        this.fly_7.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_7_MouseLeave));


        //-------------------------------VOD-------------------------------------------------------------------------
        this.fly_10 = this.content.findName("fly_10");
        this.fly_10.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_10 = this.content.findName("vorschaubild_10");
        this.Storyfly_10_MouseEnter = this.content.findName("fly_10_MouseEnter");
        this.fly_10.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_10_MouseEnter));
        this.Storyfly_10_MouseLeave = this.content.findName("fly_10_MouseLeave");
        this.fly_10.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_10_MouseLeave));
        this.fly_10.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_VOD_Film_10));

        this.fly_11 = this.content.findName("fly_11");
        this.fly_11.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_11 = this.content.findName("vorschaubild_11");
        this.Storyfly_11_MouseEnter = this.content.findName("fly_11_MouseEnter");
        this.fly_11.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_11_MouseEnter));
        this.Storyfly_11_MouseLeave = this.content.findName("fly_11_MouseLeave");
        this.fly_11.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_11_MouseLeave));
        this.fly_11.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_VOD_Film_11));

        this.fly_12 = this.content.findName("fly_12");
        this.fly_12.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_12 = this.content.findName("vorschaubild_12");
        this.Storyfly_12_MouseEnter = this.content.findName("fly_12_MouseEnter");
        this.fly_12.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_12_MouseEnter));
        this.Storyfly_12_MouseLeave = this.content.findName("fly_12_MouseLeave");
        this.fly_12.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_12_MouseLeave));
        this.fly_12.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_VOD_Film_12));

        this.fly_13 = this.content.findName("fly_13");
        this.fly_13.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_13 = this.content.findName("vorschaubild_13");
        this.Storyfly_13_MouseEnter = this.content.findName("fly_13_MouseEnter");
        this.fly_13.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_13_MouseEnter));
        this.Storyfly_13_MouseLeave = this.content.findName("fly_13_MouseLeave");
        this.fly_13.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_13_MouseLeave));
        this.fly_13.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_VOD_Film_13));

        this.fly_14 = this.content.findName("fly_14");
        this.fly_14.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_14 = this.content.findName("vorschaubild_14");
        this.Storyfly_14_MouseEnter = this.content.findName("fly_14_MouseEnter");
        this.fly_14.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_14_MouseEnter));
        this.Storyfly_14_MouseLeave = this.content.findName("fly_14_MouseLeave");
        this.fly_14.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_14_MouseLeave));
        this.fly_14.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_VOD_Film_14));

        this.fly_15 = this.content.findName("fly_15");
        this.fly_15.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_15 = this.content.findName("vorschaubild_15");
        this.Storyfly_15_MouseEnter = this.content.findName("fly_15_MouseEnter");
        this.fly_15.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_15_MouseEnter));
        this.Storyfly_15_MouseLeave = this.content.findName("fly_15_MouseLeave");
        this.fly_15.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_15_MouseLeave));
        this.fly_15.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_VOD_Film_15));

        this.fly_16 = this.content.findName("fly_16");
        this.fly_16.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_16 = this.content.findName("vorschaubild_16");
        this.Storyfly_16_MouseEnter = this.content.findName("fly_16_MouseEnter");
        this.fly_16.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_16_MouseEnter));
        this.Storyfly_16_MouseLeave = this.content.findName("fly_16_MouseLeave");
        this.fly_16.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_16_MouseLeave));
        this.fly_16.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_VOD_Film_16));

        this.fly_17 = this.content.findName("fly_17");
        this.fly_17.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_17 = this.content.findName("vorschaubild_17");
        this.Storyfly_17_MouseEnter = this.content.findName("fly_17_MouseEnter");
        this.fly_17.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_17_MouseEnter));
        this.Storyfly_17_MouseLeave = this.content.findName("fly_17_MouseLeave");
        this.fly_17.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_17_MouseLeave));
        this.fly_17.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_VOD_Film_17));

        //-------------------------------VOD END --------------------------------------------------------------------

        //-------------------------------Magazin-------------------------------------------------------------------------
        this.fly_20 = this.content.findName("fly_20");
        this.fly_20.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_20 = this.content.findName("vorschaubild_20");
        this.Storyfly_20_MouseEnter = this.content.findName("fly_20_MouseEnter");
        this.fly_20.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_20_MouseEnter));
        this.Storyfly_20_MouseLeave = this.content.findName("fly_20_MouseLeave");
        this.fly_20.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_20_MouseLeave));
        this.fly_20.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Magazin_20));




        this.fly_21 = this.content.findName("fly_21");
        this.fly_21.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_21 = this.content.findName("vorschaubild_21");
        this.Storyfly_21_MouseEnter = this.content.findName("fly_21_MouseEnter");
        this.fly_21.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_21_MouseEnter));
        this.Storyfly_21_MouseLeave = this.content.findName("fly_21_MouseLeave");
        this.fly_21.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_21_MouseLeave));
        this.fly_21.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Magazin_21));

        this.fly_22 = this.content.findName("fly_22");
        this.fly_22.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_22 = this.content.findName("vorschaubild_22");
        this.Storyfly_22_MouseEnter = this.content.findName("fly_22_MouseEnter");
        this.fly_22.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_22_MouseEnter));
        this.Storyfly_22_MouseLeave = this.content.findName("fly_22_MouseLeave");
        this.fly_22.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_22_MouseLeave));
        this.fly_22.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Magazin_22));

        this.fly_23 = this.content.findName("fly_23");
        this.fly_23.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_23 = this.content.findName("vorschaubild_23");
        this.Storyfly_23_MouseEnter = this.content.findName("fly_23_MouseEnter");
        this.fly_23.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_23_MouseEnter));
        this.Storyfly_23_MouseLeave = this.content.findName("fly_23_MouseLeave");
        this.fly_23.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_23_MouseLeave));
        this.fly_23.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Magazin_23));

        this.fly_24 = this.content.findName("fly_24");
        this.fly_24.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_24 = this.content.findName("vorschaubild_24");
        this.Storyfly_24_MouseEnter = this.content.findName("fly_24_MouseEnter");
        this.fly_24.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_24_MouseEnter));
        this.Storyfly_24_MouseLeave = this.content.findName("fly_24_MouseLeave");
        this.fly_24.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_24_MouseLeave));
        this.fly_24.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Magazin_24));

        this.fly_25 = this.content.findName("fly_25");
        this.fly_25.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_25 = this.content.findName("vorschaubild_25");
        this.Storyfly_25_MouseEnter = this.content.findName("fly_25_MouseEnter");
        this.fly_25.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_25_MouseEnter));
        this.Storyfly_25_MouseLeave = this.content.findName("fly_25_MouseLeave");
        this.fly_25.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_25_MouseLeave));
        this.fly_25.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Magazin_25));

        this.fly_26 = this.content.findName("fly_26");
        this.fly_26.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_26 = this.content.findName("vorschaubild_26");
        this.Storyfly_26_MouseEnter = this.content.findName("fly_26_MouseEnter");
        this.fly_26.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_26_MouseEnter));
        this.Storyfly_26_MouseLeave = this.content.findName("fly_26_MouseLeave");
        this.fly_26.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_26_MouseLeave));
        this.fly_26.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Magazin_26));

        this.fly_27 = this.content.findName("fly_27");
        this.fly_27.Opacity = 0.0; // Vom Start an nicht sichbar
        this.vbildblende_27 = this.content.findName("vorschaubild_27");
        this.Storyfly_27_MouseEnter = this.content.findName("fly_27_MouseEnter");
        this.fly_27.addEventListener("MouseEnter", Function.createDelegate(this, this._Storyfly_27_MouseEnter));
        this.Storyfly_27_MouseLeave = this.content.findName("fly_27_MouseLeave");
        this.fly_27.addEventListener("MouseLeave", Function.createDelegate(this, this._Storyfly_27_MouseLeave));
        this.fly_27.addEventListener("MouseLeftButtonUp", Function.createDelegate(this, this._Starte_Magazin_27));

        //-------------------------------Magazin END --------------------------------------------------------------------


        //		this.FuscreenButtonObj = this.content.findName("FullScreenButton");
        //		this.FuscreenButtonObj.addEventListener("MouseEnter", Function.createDelegate(this,this._FuscreenButtonMouseEnter));
        //		this.FuscreenButtonObj.addEventListener("MouseLeave", Function.createDelegate(this,this._FuscreenButtonMouseLeave));

        // Story boards Live Tab		
        this.StorySlideInLive = this.content.findName("liveslide_inout");
        this.StorySlideOutLive = this.content.findName("liveslide_out");

        this.StorySlideInLiveMagout = this.content.findName("Liveslide_in_Magout");
        this.StorySlideInLiveVoDout = this.content.findName("Liveslide_in_VoDout");
        this.StorySlideInVoDLiveout = this.content.findName("VoDslide_in_Liveout");


        this.StoryepgLeftSlide = this.content.findName("epgLeftSlide");
        this.StoryepgRightSlide = this.content.findName("epgRightSlide");
        //-----------------------	
        // Story boards VoD Tab		
        this.StorySlideInVoD = this.content.findName("VoDslide_in");
        this.StorySlideOutVoD = this.content.findName("VoDslide_out");

        this.StoryepgvodLeftSlide = this.content.findName("epgvodLeftSlide");
        this.StoryepgvodRightSlide = this.content.findName("epgvodRightSlide");
        //-----------------------			
        //-----------------------	
        // Story boards Magazin Tab		
        this.StorySlideInMag = this.content.findName("Magazinslide_in");
        this.StorySlideOutMag = this.content.findName("Magazinslide_out");
        this.StorySlideoutMag_VoDin = this.content.findName("Magazinslide_out_VoDin");
        this.StorySlideinMag_VoDout = this.content.findName("Magazinslide_in_VoDout");
        this.StorySlideinMag_Liveout = this.content.findName("Magazinslide_in_Liveout");
        this.StoryepgmagLeftSlide = this.content.findName("epgmagLeftSlide");
        this.StoryepgmagRightSlide = this.content.findName("epgmagRightSlide");

        this.StorySlideOutModblende = this.content.findName("Modblende_out");
        this.MagazinBlackBlende = this.content.findName("MagazinBlackBlende");


        this.StoryVolumeControlMouseLeave = this.content.findName("VolumeControlRect_MouseLeave");
        this.StoryVolumeControlMouseEnter = this.content.findName("VolumeControlRect_MouseEnter");

        this.VolumeThumbShape = this.content.findName("VolumeThumb");
        this.VolumeThumbShape.addEventListener("MouseEnter", Function.createDelegate(this, this._StoryVolumeControlMouseEnter));
        this.VolumeThumbShape.addEventListener("MouseLeave", Function.createDelegate(this, this._StoryVolumeControlMouseLeave));
        this.VolumeControlRect = this.content.findName("VolumeControlRect");

        //-----------------------	


        //	this.StorySlideOutLive = this.content.findName("liveslide_out");
        //	this.StoryepgLeftSlide = this.content.findName("epgLeftSlide");
        //	this.StoryepgRightSlide = this.content.findName("epgRightSlide");


        //this.StorySlideOutLive = this.content.findName("liveslide_out");

        //Eigene  Eventhandler




        // Startinitialisierung
        //this._playNextVideo();
        //this._SlideInLive();
        this.epgpanel = this.content.findName("epg");
        this.epgpanel.opacity = 0;

        //this._SlideInLive();
        this.vodpanel = this.content.findName("epg1");
        this.vodpanel.opacity = 0;



        //alert(SLChangeMagURL(-1));
        //this.StorySlideInMag.begin();
        //Magrefresh();
        SLChangeMagURL(-1); //former -1
        //alert(FlagMagOn);
        FlagMagOn = true;
        FlagMagRunning = true;
        AnzEintraege_Mag = 8;
        AktuelleMagPosition = 0;
        
        //this.StorySlideOutLive.begin();
        //this.control.content.findName("Magazinslide_in").Begin();
		//alert("test1");
		this.StorySlideInMag.begin();
		//alert("test2");   


    },
    _onMediaEnded: function(sender, eventArgs) {
        //window.setTimeout( Function.createDelegate(this, this._playNextVideo), 1000);
    	//alert("_onMediaEnded-live  FlagMagRunning:"+FlagMagRunning+" FlagLiveRunning:"+FlagLiveRunning);
    	//alert("OnMediaEnded2  FlagMagRunning:"+FlagMagRunning+ "  AktuelleMagPosition: "+AktuelleMagPosition+ "  AnzEintraege_Mag"+ AnzEintraege_Mag+" FlagLiveRunning:"+FlagLiveRunning");
        if ((FlagMagRunning == true) && (AktuelleMagPosition + 1 < AnzEintraege_Mag)) {
        	//alert("OnMediaEnded2");
            if ((AktuelleMagPosition + 1) < AnzahlBoxenMag) {
            	//alert("OnMediaEnded3");
                //if (AktuelleMagPosition != -1) {AktuelleMagPosition++;}
                AktuelleMagPosition++;
                // Anhalten nach der Moderation
                //				if (AktuelleMagPosition >0) {SLChangeMagURL( AktuelleMagPosition);}
                // Automatische weiterlaufen nach der Moderation
                SLChangeMagURL(AktuelleMagPosition);


            } else {
                this._ButtChapterArea_ScrollNext_mag();
                SLChangeMagURL(AktuelleMagPosition);
            }
            this._setzeblendeMag(sender, eventArgs);
            if (AktuelleMagPosition < 1) { this.StorySlideOutModblende.begin(); }

        } else if (FlagLiveRunning == true) {
            
            //_restartplay();
        	EPGrefresh();
            if (SLRestartOnPlaylistEnd) {
                //window.setTimeout( Function.createDelegate(this, this._playNextVideo), SLASXMaxTimeSek /*1000*/);
                this._playNextVideo();
                this._player.play();
                FlagLiveRunning = true;
            }
            //this._currentMediainfo = 2;
            //this._player.set_mediainfo( get_mediainfo( this._currentMediainfo ));
        }
    },
    _onMediaFailed: function(sender, eventArgs) {
        alert(String.format(Ee.UI.Xaml.Media.Res.mediaFailed, this._player.get_mediaUrl()));
    },

    _playNextVideo: function() {
        var cVideos = 3;

        if (GlobalClipID != "") {
            //play mit  GlobalClipID     SLmedia.Source = "../../test/player_asx/asxgen.php?MandantID=2&channelID=1&typ=.wmv&SpeedID="+SLActualSpeed+"&FilmID="+SLActualFilmID;
            //Video einem Freund Empfehen. hier wird die übergebene FilID anstatt der normalen Ausführung gewählt
            this._player.set_mediainfo(get_mediainfo(this._currentMediainfo));
            SLActualFilmID = GlobalClipID;
            GlobalClipID = "";
            this._player._mediaUrl = "../../test/player_asx/asxgen.php?MandantID=2&channelID=1&SpeedID=" + SLActualSpeed + "&FilmID=" + SLActualFilmID + "&typ=.wmv";
            this._player.play();
        }
        else { // Normaler Anfang
            if (this._currentMediainfo < cVideos)
                this._player.set_mediainfo(get_mediainfo(this._currentMediainfo));

        }

    },

    _Starte_ExterneSeite: function(sender, eventArgs) {


        //fenster = window.open ("http://www.ziggyfilm.tv/cms/tvsender/stations/ziggy/nuernbergplayer/", 'Leinwand', 'top=10,left=10,height=818,width=1024,resizable=yes');
        this.HTMLcms_layer = document.getElementById('cms_layer');
        this.HTMLcms_frame = document.getElementById('cms_frame');
        //this.HTMLcms_frame.location.href='../../../../index3.php?option=com_recommend&Itemid=61';
        this.HTMLcms_frame.src = "../../../../index3.php?option=com_login&Itemid=62&clipid=" + SLActualFilmID;
        if (this.HTMLcms_layer != null) {
            this.HTMLcms_layer.style.top = cms_layer_position_y;
            this.HTMLcms_layer.style.left = cms_layer_position_x;
            this.HTMLcms_layer.style.height = cms_layer_hoehe + 20;
            this.HTMLcms_layer.style.width = cms_layer_breite;
        }
        if (this.HTMLcms_frame != null) {
            this.HTMLcms_frame.style.top = cms_layer_position_y;
            this.HTMLcms_frame.style.left = cms_layer_position_x;
            this.HTMLcms_frame.style.height = cms_layer_hoehe;
            this.HTMLcms_frame.style.width = cms_layer_breite;
        }


    },

    _Starte_Impressum: function(sender, eventArgs) {


        //fenster = window.open ("http://www.ziggyfilm.tv/cms/tvsender/stations/ziggy/nuernbergplayer/", 'Leinwand', 'top=10,left=10,height=818,width=1024,resizable=yes');
        this.HTMLcms_layer = document.getElementById('cms_layer');
        this.HTMLcms_frame = document.getElementById('cms_frame');
        //this.HTMLcms_frame.location.href='../../../../index3.php?option=com_recommend&Itemid=61';
        this.HTMLcms_frame.src = "../../../../index3.php?option=com_content&task=view&id=13&Itemid=27&clipid=" + SLActualFilmID;
        if (this.HTMLcms_layer != null) {
            this.HTMLcms_layer.style.top = cms_layer_position_y;
            this.HTMLcms_layer.style.left = cms_layer_position_x;
            this.HTMLcms_layer.style.height = cms_layer_hoehe + 20;
            this.HTMLcms_layer.style.width = cms_layer_breite;
        }
        if (this.HTMLcms_frame != null) {
            this.HTMLcms_frame.style.top = cms_layer_position_y;
            this.HTMLcms_frame.style.left = cms_layer_position_x;
            this.HTMLcms_frame.style.height = cms_layer_hoehe;
            this.HTMLcms_frame.style.width = cms_layer_breite;
        }


    },

    _Starte_Kontakt: function(sender, eventArgs) {

        //fenster = window.open ("http://www.ziggyfilm.tv/cms/tvsender/stations/ziggy/nuernbergplayer/", 'Leinwand', 'top=10,left=10,height=818,width=1024,resizable=yes');
        this.HTMLcms_layer = document.getElementById('cms_layer');
        this.HTMLcms_frame = document.getElementById('cms_frame');
        //this.HTMLcms_frame.location.href='../../../../index3.php?option=com_recommend&Itemid=61';
        this.HTMLcms_frame.src = "../../../../index3.php?option=com_contact&Itemid=3&clipid=" + SLActualFilmID;
        if (this.HTMLcms_layer != null) {
            this.HTMLcms_layer.style.top = cms_layer_position_y;
            this.HTMLcms_layer.style.left = cms_layer_position_x;
            this.HTMLcms_layer.style.height = cms_layer_hoehe + 20;
            this.HTMLcms_layer.style.width = cms_layer_breite;
        }
        if (this.HTMLcms_frame != null) {
            this.HTMLcms_frame.style.top = cms_layer_position_y;
            this.HTMLcms_frame.style.left = cms_layer_position_x;
            this.HTMLcms_frame.style.height = cms_layer_hoehe;
            this.HTMLcms_frame.style.width = cms_layer_breite;
        }


    },

    _TellAFriendMouseEnter: function(sender, eventArgs) {
        this.TellAFriend.Opacity = 1;
        this.TelafriendFlyMouse.Opacity = 1;

    },

    _TellAFriendMouseLeave: function(sender, eventArgs) {
        this.TellAFriend.Opacity = 0.3;
        this.TelafriendFlyMouse.Opacity = 0;
    },

    _infoMouseEnter: function(sender, eventArgs) {
        this.info.Opacity = 1;
        this.infoFlyMouse.Opacity = 1;
    },

    _infoMouseLeave: function(sender, eventArgs) {
        this.info.Opacity = 0.3;
        this.infoFlyMouse.Opacity = 0;
    },


    _TellAFriend_ExterneSeite: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');

        this.HTMLcms_layer = document.getElementById('cms_layer');
        this.HTMLcms_frame = document.getElementById('cms_frame');
        //this.HTMLcms_frame.location.href='../../../../index3.php?option=com_recommend&Itemid=61';
        this.HTMLcms_frame.src = "../../../../index3.php?option=com_recommend&Itemid=61&clipid=" + SLActualFilmID;
        if (this.HTMLcms_layer != null) {
            this.HTMLcms_layer.style.top = cms_layer_position_y;
            this.HTMLcms_layer.style.left = cms_layer_position_x;
            this.HTMLcms_layer.style.height = cms_layer_hoehe + 20;
            this.HTMLcms_layer.style.width = cms_layer_breite;
        }
        if (this.HTMLcms_frame != null) {
            this.HTMLcms_frame.style.top = cms_layer_position_y;
            this.HTMLcms_frame.style.left = cms_layer_position_x;
            this.HTMLcms_frame.style.height = cms_layer_hoehe;
            this.HTMLcms_frame.style.width = cms_layer_breite;
        }
    },
    _info: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');
        //alert("_info_");	

        this.HTMLcms_layer = document.getElementById('cms_layer');
        this.HTMLcms_frame = document.getElementById('cms_frame');
        //alert("frame"+this.HTMLcms_frame.contentWindow.location.href); // http://www.ziggyfilm.tv/cms/index.php?option=com_content&task=view&id=13&Itemid=27
        //http://www.ziggyfilm.tv/cms/tvsender/stations/test/player_asx/filminfogen.php?MandantID=2&channelID=1&filmid=480&typ=.wmv
        this.HTMLcms_frame.contentWindow.location.href = "../../test/player_asx/filminfogen.php?MandantID=2&channelID=1&filmid=" + SLActualFilmID;
        //this.HTMLcms_frame.contentWindow.location.reload();
        if (this.HTMLcms_layer != null) {
            this.HTMLcms_layer.style.top = cms_layer_position_y;
            this.HTMLcms_layer.style.left = cms_layer_position_x;
            this.HTMLcms_layer.style.height = cms_layer_hoehe + 20;
            this.HTMLcms_layer.style.width = cms_layer_breite;
        }
        if (this.HTMLcms_frame != null) {
            this.HTMLcms_frame.style.top = cms_layer_position_y;
            this.HTMLcms_frame.style.left = cms_layer_position_x;
            this.HTMLcms_frame.style.height = cms_layer_hoehe;
            this.HTMLcms_frame.style.width = cms_layer_breite;
        }

    },

    _StoryVolumeControlMouseEnter: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');
        //alert("_1_");	
        //	if (VolumeAusgefahren == false) {
        //		VolumeAusgefahren = true;
        //		this.StoryVolumeControlMouseEnter.begin();
        //		window.setTimeout("VolumeAusgefahren = false;",5000);
        //	}	
        this.VolumeThumbShape.opacity = 1;


    },

    _StoryVolumeControlMouseLeave: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');
        //alert("_1_");	
        //		window.setTimeout("StoryVolumeControlSchliessen()",5000);
        //		if (VolumeAusgefahren == false) {
        //			this.StoryVolumeControlMouseLeave.begin();
        //		}
        //alert("leave");
        this.VolumeThumbShape.opacity = 0.6;
    },



    _FadeInExtended: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');
        //alert("_1_");	
        this.StoryInExtended.begin();
    },
    _FadeOutExtended: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');
        //alert("_1_");	
        this.StoryOutExtended.begin();
    },
    _Bewertung_spot_1: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');
        //alert("_1_");	
        this.Bewertung_spot_1_c.opacity = 1;
        this.Bewertung_spot_2_c.opacity = 0;
        this.Bewertung_spot_3_c.opacity = 0;
        this.Bewertung_spot_4_c.opacity = 0;
        this.Bewertung_spot_5_c.opacity = 0;
        this.StoryBewertung.begin();
        setze_bewertung(1);
    },
    _Bewertung_spot_2: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');
        //alert("_2_");	
        this.Bewertung_spot_1_c.opacity = 1;
        this.Bewertung_spot_2_c.opacity = 1;
        this.Bewertung_spot_3_c.opacity = 0;
        this.Bewertung_spot_4_c.opacity = 0;
        this.Bewertung_spot_5_c.opacity = 0;
        this.StoryBewertung.begin();
        setze_bewertung(2);
    },
    _Bewertung_spot_3: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');
        //alert("_3_");	
        this.Bewertung_spot_1_c.opacity = 1;
        this.Bewertung_spot_2_c.opacity = 1;
        this.Bewertung_spot_3_c.opacity = 1;
        this.Bewertung_spot_4_c.opacity = 0;
        this.Bewertung_spot_5_c.opacity = 0;
        this.StoryBewertung.begin();
        setze_bewertung(3);
    },
    _Bewertung_spot_4: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');
        //alert("_4_");	
        this.Bewertung_spot_1_c.opacity = 1;
        this.Bewertung_spot_2_c.opacity = 1;
        this.Bewertung_spot_3_c.opacity = 1;
        this.Bewertung_spot_4_c.opacity = 1;
        this.Bewertung_spot_5_c.opacity = 0;

        this.StoryBewertung.begin();
        setze_bewertung(4);
    },
    _Bewertung_spot_5: function(sender, eventArgs) {
        //fenster = window.open ("http://www.ziggyfilm.tv/cms/index2.php?option=com_recommend&Itemid=61", 'Leinwand', 'top=10,left=10,height=350,width=400,resizable=no');
        //alert("_5_");	
        this.Bewertung_spot_1_c.opacity = 1;
        this.Bewertung_spot_2_c.opacity = 1;
        this.Bewertung_spot_3_c.opacity = 1;
        this.Bewertung_spot_4_c.opacity = 1;
        this.Bewertung_spot_5_c.opacity = 1;
        this.StoryBewertung.begin();
        setze_bewertung(5);
    },

    _touchVotingEnter: function(sender, eventArgs) {
        this.touchVoting.Opacity = 1;
    },
    _touchVotingLeave: function(sender, eventArgs) {
        this.touchVoting.Opacity = 0.3;
    },

    _touchImpressumEnter: function(sender, eventArgs) {
        this.touchImpressum.Opacity = 1;
    },
    _touchImpressumLeave: function(sender, eventArgs) {
        this.touchImpressum.Opacity = 0.6;
    },

    _touchKontaktEnter: function(sender, eventArgs) {
        this.touchKontakt.Opacity = 1;
    },
    _touchKontaktLeave: function(sender, eventArgs) {
        this.touchKontakt.Opacity = 0.6;
    },









    _dsl500a: function(sender, eventArgs) {
        this.Emupdsl500.Opacity = 1;   //alert("aaa500");
    },
    _dsl500i: function(sender, eventArgs) {
        //sender.Source="images/buttons/dsl500.png";
        if (SLActualSpeed == 3) { //alert("500");
            //alert("---"+eventArgs);	
            // sender.Source="images/buttons/dsl500_mouseover.png";
            //var dsl500butt = sender.findName("dsl500");alert("test"+dsl500butt);	
            this.Emupdsl500.Opacity = 1;
            this.Emupdsl1500.Opacity = 0.5;
            this.Emupdsl2500.Opacity = 0.5;
            //alert(this._player.);
            /*			sender.Source="images/buttons/dsl500_mouseover.png"; 
            this._player.Edsl1500.Source = "images/buttons/dsl1500.png";//plugIn.Content.findName('dsl500');
            this._player.Edsl2500.Source = "images/buttons/dsl2500.png";//plugIn.Content.findName('dsl500');*/
        } else {
            this.Emupdsl500.Opacity = 0.5;
        }
    },
    _dsl1500a: function(sender, eventArgs) {
        sender.Opacity = 1;   //alert("aaa1500");
    },
    _dsl1500i: function(sender, eventArgs) {
        //sender.Source="images/buttons/dsl500.png";
        if (SLActualSpeed == 4) { //alert("1500");
            //alert("---"+eventArgs);	
            // sender.Source="images/buttons/dsl500_mouseover.png";
            //var dsl500butt = sender.findName("dsl500");alert("test"+dsl500butt);	
            this.Emupdsl500.Opacity = 0.5;
            this.Emupdsl1500.Opacity = 1;
            this.Emupdsl2500.Opacity = 0.5;
            //alert(this._player.);
            /*			sender.Source="images/buttons/dsl500_mouseover.png"; 
            this._player.Edsl1500.Source = "images/buttons/dsl1500.png";//plugIn.Content.findName('dsl500');
            this._player.Edsl2500.Source = "images/buttons/dsl2500.png";//plugIn.Content.findName('dsl500');*/
        } else {
            this.Emupdsl1500.Opacity = 0.5;
        }
    },
    _dsl2500a: function(sender, eventArgs) {
        sender.Opacity = 1;  //alert("aaa1500");
    },
    _dsl2500i: function(sender, eventArgs) {
        //sender.Source="images/buttons/dsl500.png";
        if (SLActualSpeed == 5) { //alert("1500");
            //alert("---"+eventArgs);	
            // sender.Source="images/buttons/dsl500_mouseover.png";
            //var dsl500butt = sender.findName("dsl500");alert("test"+dsl500butt);	
            this.Emupdsl500.Opacity = 0.5;
            this.Emupdsl1500.Opacity = 0.5;
            this.Emupdsl2500.Opacity = 1;
            //alert(this._player.);
            /*			sender.Source="images/buttons/dsl500_mouseover.png"; 
            this._player.Edsl1500.Source = "images/buttons/dsl1500.png";//plugIn.Content.findName('dsl500');
            this._player.Edsl2500.Source = "images/buttons/dsl2500.png";//plugIn.Content.findName('dsl500');*/
        } else {
            this.Emupdsl2500.Opacity = 0.5;
        }
    },

    _dsl500: function(sender, eventArgs) {
        this._currentMediainfo = 0;
        SLActualSpeed = 3; //Globale Speedvariable
        if (FlagMagRunning == true) {
            //Magazin Umschaltung
            SLChangeMagURL(AktuelleMagPosition);


        } else if (FlagLiveRunning == true) {
            // Liveumschaltung
            this._player.set_mediainfo(get_mediainfo(0));

        } else {
            // VoD Umschaltung
            SLChangeURL(AktuelleVodPosition);
        }
    },

    _dsl1500: function(sender, eventArgs) {
        this._currentMediainfo = 1;
        SLActualSpeed = 4; //Globale Speedvariable

        if (FlagMagRunning == true) {
            //Magazin Umschaltung
            SLChangeMagURL(AktuelleMagPosition);


        } else if (FlagLiveRunning == true) {
            // Liveumschaltung
            this._player.set_mediainfo(get_mediainfo(1));

        } else {
            // VoD Umschaltung
            SLChangeURL(AktuelleVodPosition);
        }


    },
    _dsl2500: function(sender, eventArgs) {
        this._currentMediainfo = 2;
        SLActualSpeed = 5; //Globale Speedvariable

        if (FlagMagRunning == true) {
            //Magazin Umschaltung
            SLChangeMagURL(AktuelleMagPosition);

        } else if (FlagLiveRunning == true) {
            // Liveumschaltung
            this._player.set_mediainfo(get_mediainfo(2));

        } else {
            // VoD Umschaltung
            SLChangeURL(AktuelleVodPosition);
        }

    },





    // Eigene Eventhandler Funktionen
    _SlideInLive: function(sender, eventArgs) {
        //alert("_SlideInLive");
        cms_layerSchliessen();

        this.MagazinBlackBlende.Opacity = 0;
        if (FlagLiveOn == false) {  // Live ausgeblendet

            if (FlagVoDOn == true) {
                this.StorySlideInLiveVoDout.begin();
                //this.StorySlideOutVoD.begin();
                FlagVoDOn = false;
            } else if (FlagMagOn == true) {

                this.StorySlideInLiveMagout.begin();
                FlagMagOn = false;
                FlagMagRunning = false;
            } else {
                this.StorySlideInLive.begin();
            }
            //this.StorySlideInLiveUVoD2.begin();
            //this.StorySlideOutVoD.begin();
            FlagVoDOn = false; FlagMagOn = false;
            this.epgpanel.opacity = 100;

            // akm     playnext  wenn grundsätzlich neu initialisiert werden soll.
            if (FlagLiveRunning == false) {
                this._playNextVideo();
                this._player.play(); //alert("_playnext");
                FlagLiveRunning = true;
            }

            FlagLiveOn = true; FlagMagOn = false; FlagVoDOn = false;
        } else {	// Livepanel zurückfahren
            this.StorySlideOutLive.begin();
            FlagLiveOn = false;
        }
    },

    _SlideInVoD: function(sender, eventArgs) {
        cms_layerSchliessen();
        VODrefresh(1);
        this.MagazinBlackBlende.Opacity = 0; //alert("_SlideInVoD");
        if (FlagVoDOn == false) {
            if (FlagLiveOn == true) {
                this.StorySlideInVoDLiveout.begin();

                //this.StorySlideInVoD.begin.begin();
            } else if (FlagMagOn == true) {

                this.StorySlideoutMag_VoDin.begin();
                //SLChangeVoDURL( -1);
                //this.StorySlideInVoD.begin.begin();
            } else {	// normales ausfahren des VOD Panels
                this.StorySlideInVoD.begin();
                //this.StorySlideInVoD.begin();	
            }
            FlagLiveOn = false; FlagMagOn = false; FlagVoDOn = true;
            FlagMagRunning = false;
            this.vodpanel.opacity = 100;
            SLChangeVoDURL( -1);


        } else {
            this.StorySlideOutVoD.begin();
            FlagVoDOn = false;
        }
    },

    _VOD_refresh_filter_1: function(sender, eventArgs) {
        VODrefresh(1);
        this.Topfilter_1.Opacity = 1;
        this.Topfilter_2.Opacity = 0.5;
        this.Topfilter_3.Opacity = 0.5;
        this.Topfilter_4.Opacity = 0.5;

        this.Topfilter_5.Opacity = 0.5;
        this.Topfilter_6.Opacity = 0.5;
        this.Topfilter_7.Opacity = 0.5;
        this.Topfilter_8.Opacity = 0.5;
    },
    _VOD_refresh_filter_2: function(sender, eventArgs) {
        VODrefresh(2);
        this.Topfilter_1.Opacity = 0.5;
        this.Topfilter_2.Opacity = 1;
        this.Topfilter_3.Opacity = 0.5;
        this.Topfilter_4.Opacity = 0.5;

        this.Topfilter_5.Opacity = 0.5;
        this.Topfilter_6.Opacity = 0.5;
        this.Topfilter_7.Opacity = 0.5;
        this.Topfilter_8.Opacity = 0.5;
    },
    _VOD_refresh_filter_3: function(sender, eventArgs) {
        VODrefresh(3);
        this.Topfilter_1.Opacity = 0.5;
        this.Topfilter_2.Opacity = 0.5;
        this.Topfilter_3.Opacity = 1;
        this.Topfilter_4.Opacity = 0.5;

        this.Topfilter_5.Opacity = 0.5;
        this.Topfilter_6.Opacity = 0.5;
        this.Topfilter_7.Opacity = 0.5;
        this.Topfilter_8.Opacity = 0.5;
    },
    _VOD_refresh_filter_4: function(sender, eventArgs) {
        VODrefresh(4);
        this.Topfilter_1.Opacity = 0.5;
        this.Topfilter_2.Opacity = 0.5;
        this.Topfilter_3.Opacity = 0.5;
        this.Topfilter_4.Opacity = 1;

        this.Topfilter_5.Opacity = 0.5;
        this.Topfilter_6.Opacity = 0.5;
        this.Topfilter_7.Opacity = 0.5;
        this.Topfilter_8.Opacity = 0.5;
    },
    _VOD_refresh_filter_5: function(sender, eventArgs) {
        VODrefresh(5);
        this.Topfilter_1.Opacity = 0.5;
        this.Topfilter_2.Opacity = 0.5;
        this.Topfilter_3.Opacity = 0.5;
        this.Topfilter_4.Opacity = 0.5;

        this.Topfilter_5.Opacity = 1;
        this.Topfilter_6.Opacity = 0.5;
        this.Topfilter_7.Opacity = 0.5;
        this.Topfilter_8.Opacity = 0.5;
    },
    _VOD_refresh_filter_6: function(sender, eventArgs) {
        VODrefresh(6);
        this.Topfilter_1.Opacity = 0.5;
        this.Topfilter_2.Opacity = 0.5;
        this.Topfilter_3.Opacity = 0.5;
        this.Topfilter_4.Opacity = 0.5;

        this.Topfilter_5.Opacity = 0.5;
        this.Topfilter_6.Opacity = 1;
        this.Topfilter_7.Opacity = 0.5;
        this.Topfilter_8.Opacity = 0.5;
    },
    _VOD_refresh_filter_7: function(sender, eventArgs) {
        VODrefresh(7);
        this.Topfilter_1.Opacity = 0.5;
        this.Topfilter_2.Opacity = 0.5;
        this.Topfilter_3.Opacity = 0.5;
        this.Topfilter_4.Opacity = 0.5;

        this.Topfilter_5.Opacity = 0.5;
        this.Topfilter_6.Opacity = 0.5;
        this.Topfilter_7.Opacity = 1;
        this.Topfilter_8.Opacity = 0.5;
    },
    _VOD_refresh_filter_8: function(sender, eventArgs) {
        VODrefresh(8);
        this.Topfilter_1.Opacity = 0.5;
        this.Topfilter_2.Opacity = 0.5;
        this.Topfilter_3.Opacity = 0.5;
        this.Topfilter_4.Opacity = 0.5;

        this.Topfilter_5.Opacity = 0.5;
        this.Topfilter_6.Opacity = 0.5;
        this.Topfilter_7.Opacity = 0.5;
        this.Topfilter_8.Opacity = 1;
    },

    _SlideInMagazin: function(sender, eventArgs) {
        cms_layerSchliessen();
        Magrefresh();
        //alert("_SlideInVoD");
        if (FlagMagOn == false) {
            if (FlagLiveOn == true) {
                this.StorySlideinMag_Liveout.begin();

                //this.StorySlideInVoD.begin.begin();
            } else if (FlagVoDOn == true) {

                this.StorySlideinMag_VoDout.begin();
                SLChangeMagURL(-1);
                //this.StorySlideInVoD.begin.begin();
            } else {	// normales ausfahren des VOD Panels
                this.vodpanel.opacity = 100;
                this.StorySlideInMag.begin();
            }
            FlagLiveOn = false; FlagVoDOn = false; FlagMagOn = true;
            
            if (FlagMagFirst == false){
            	this._player.stop(); FlagLiveRunning = false;
            	SLChangeMagURL(-1);
        		} else {
            	FlagMagFirst = false;
        		}

        } else {
        	
        	if (FlagMagFirst == false){  // beim ersten Start des Players soll das Magazin nicght neu gestartet werden da es schon laeuft
            this.StorySlideOutMag.begin();
        	FlagMagOn = false;
        	}	else this.StorySlideInMag.begin();
            
        }
    },
    _Storyfly_0_MouseEnter: function() {
        this.Storyfly_0_MouseEnter.begin();
        this.vbildblende_0.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_0_MouseLeave: function() {
        this.Storyfly_0_MouseLeave.begin();
        //this.vbildblende_0.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_1_MouseEnter: function() {
        this.Storyfly_1_MouseEnter.begin();
        this.vbildblende_1.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_1_MouseLeave: function() {
        this.Storyfly_1_MouseLeave.begin();
        //this.vbildblende_1.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_2_MouseEnter: function() {
        this.Storyfly_2_MouseEnter.begin();
        this.vbildblende_2.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_2_MouseLeave: function() {
        this.Storyfly_2_MouseLeave.begin();
        this.vbildblende_2.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_3_MouseEnter: function() {
        this.Storyfly_3_MouseEnter.begin();
        this.vbildblende_3.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_3_MouseLeave: function() {
        this.Storyfly_3_MouseLeave.begin();
        this.vbildblende_3.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_4_MouseEnter: function() {
        this.Storyfly_4_MouseEnter.begin();
        this.vbildblende_4.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_4_MouseLeave: function() {
        this.Storyfly_4_MouseLeave.begin();
        this.vbildblende_4.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_5_MouseEnter: function() {
        this.Storyfly_5_MouseEnter.begin();
        this.vbildblende_5.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_5_MouseLeave: function() {
        this.Storyfly_5_MouseLeave.begin();
        this.vbildblende_5.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_6_MouseEnter: function() {
        this.Storyfly_6_MouseEnter.begin();
        this.vbildblende_6.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_6_MouseLeave: function() {
        this.Storyfly_6_MouseLeave.begin();
        this.vbildblende_6.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_7_MouseEnter: function() {
        this.Storyfly_7_MouseEnter.begin();
        this.vbildblende_7.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_7_MouseLeave: function() {
        this.Storyfly_7_MouseLeave.begin();
        this.vbildblende_7.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },

    //-------------------------VOD---------------------------

    _Storyfly_10_MouseEnter: function() {
        this.Storyfly_10_MouseEnter.begin();
        this.vbildblende_10.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_10_MouseLeave: function() {
        this.Storyfly_10_MouseLeave.begin();
        if (AktuelleVodPosition != 0) this.vbildblende_10.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_11_MouseEnter: function() {
        this.Storyfly_11_MouseEnter.begin();
        this.vbildblende_11.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_11_MouseLeave: function() {
        this.Storyfly_11_MouseLeave.begin();
        if (AktuelleVodPosition != 1) this.vbildblende_11.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_12_MouseEnter: function() {
        this.Storyfly_12_MouseEnter.begin();
        this.vbildblende_12.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_12_MouseLeave: function() {
        this.Storyfly_12_MouseLeave.begin();
        if (AktuelleVodPosition != 2) this.vbildblende_12.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_13_MouseEnter: function() {
        this.Storyfly_13_MouseEnter.begin();
        this.vbildblende_13.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_13_MouseLeave: function() {
        this.Storyfly_13_MouseLeave.begin();
        if (AktuelleVodPosition != 3) this.vbildblende_13.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_14_MouseEnter: function() {
        this.Storyfly_14_MouseEnter.begin();
        this.vbildblende_14.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_14_MouseLeave: function() {
        this.Storyfly_14_MouseLeave.begin();
        if (AktuelleVodPosition != 4) this.vbildblende_14.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_15_MouseEnter: function() {
        this.Storyfly_15_MouseEnter.begin();
        this.vbildblende_15.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_15_MouseLeave: function() {
        this.Storyfly_15_MouseLeave.begin();
        if (AktuelleVodPosition != 5) this.vbildblende_15.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_16_MouseEnter: function() {
        this.Storyfly_16_MouseEnter.begin();
        this.vbildblende_16.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_16_MouseLeave: function() {
        this.Storyfly_16_MouseLeave.begin();
        if (AktuelleVodPosition != 6) this.vbildblende_16.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_17_MouseEnter: function() {
        this.Storyfly_17_MouseEnter.begin();
        this.vbildblende_17.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_17_MouseLeave: function() {
        this.Storyfly_17_MouseLeave.begin();
        if (AktuelleVodPosition != 7) this.vbildblende_17.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },

    //-------------------------magazin---------------------------

    _Storyfly_20_MouseEnter: function() {
        this.Storyfly_20_MouseEnter.begin();
        this.vbildblende_20.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_20_MouseLeave: function() {
        this.Storyfly_20_MouseLeave.begin();
        if (AktuelleMagPosition != 0) this.vbildblende_20.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_21_MouseEnter: function() {
        this.Storyfly_21_MouseEnter.begin();
        this.vbildblende_21.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_21_MouseLeave: function() {
        this.Storyfly_21_MouseLeave.begin();
        if (AktuelleMagPosition != 1) this.vbildblende_21.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_22_MouseEnter: function() {
        this.Storyfly_22_MouseEnter.begin();
        this.vbildblende_22.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_22_MouseLeave: function() {
        this.Storyfly_22_MouseLeave.begin();
        if (AktuelleMagPosition != 2) this.vbildblende_22.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_23_MouseEnter: function() {
        this.Storyfly_23_MouseEnter.begin();
        this.vbildblende_23.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_23_MouseLeave: function() {
        this.Storyfly_23_MouseLeave.begin();
        if (AktuelleMagPosition != 3) this.vbildblende_23.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_24_MouseEnter: function() {
        this.Storyfly_24_MouseEnter.begin();
        this.vbildblende_24.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_24_MouseLeave: function() {
        this.Storyfly_24_MouseLeave.begin();
        if (AktuelleMagPosition != 4) this.vbildblende_24.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_25_MouseEnter: function() {
        this.Storyfly_25_MouseEnter.begin();
        this.vbildblende_25.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_25_MouseLeave: function() {
        this.Storyfly_25_MouseLeave.begin();
        if (AktuelleMagPosition != 5) this.vbildblende_25.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_26_MouseEnter: function() {
        this.Storyfly_26_MouseEnter.begin();
        this.vbildblende_26.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_26_MouseLeave: function() {
        this.Storyfly_26_MouseLeave.begin();
        if (AktuelleMagPosition != 6) this.vbildblende_26.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },
    _Storyfly_27_MouseEnter: function() {
        this.Storyfly_27_MouseEnter.begin();
        this.vbildblende_27.Opacity = 1;
        //this.fly_2.Layout.Top = -72;
    },
    _Storyfly_27_MouseLeave: function() {
        this.Storyfly_27_MouseLeave.begin();
        if (AktuelleMagPosition != 7) this.vbildblende_27.Opacity = 0.3;
        //this.fly_2.Layout.Top = 24;
    },

    _setzeblendeVod: function(sender, eventArgs) {

        // Alle Blenden einschalten
        this.vbildblende_10.Opacity = 0.3;
        this.vbildblende_11.Opacity = 0.3;
        this.vbildblende_12.Opacity = 0.3;
        this.vbildblende_13.Opacity = 0.3;
        this.vbildblende_14.Opacity = 0.3;
        this.vbildblende_15.Opacity = 0.3;
        this.vbildblende_16.Opacity = 0.3;
        this.vbildblende_17.Opacity = 0.3;

        // Blende des laufenden Film öffnen
        switch (AktuelleMagPosition) {
            case 0: this.vbildblende_10.Opacity = 1; break;
            case 1: this.vbildblende_11.Opacity = 1; break;
            case 2: this.vbildblende_12.Opacity = 1; break;
            case 3: this.vbildblende_13.Opacity = 1; break;
            case 4: this.vbildblende_14.Opacity = 1; break;
            case 5: this.vbildblende_15.Opacity = 1; break;
            case 6: this.vbildblende_16.Opacity = 1; break;
            case 7: this.vbildblende_17.Opacity = 1; break;
        }

    },


    //	_Starte_Magazin_26: function(sender, eventArgs) {
    //		AktuelleMagPosition = 6;
    //		this._setzeblendeMag(sender, eventArgs);
    //		this.vbildblende_26.Opacity = 0.0; 		
    //		SLChangeMagURL( AktuelleMagPosition);
    //		FlagLiveRunning = false;
    //		FlagMagRunning = true;
    //		//this.StoryepgRightSlide.begin();
    //	},
    // sender, eventArgs  _Starte_VOD_Film
    _Starte_VOD_Film_10: function(sender, eventArgs) {
        AktuelleVodPosition = 0;
        this._setzeblendeVod(sender, eventArgs);
        this.vbildblende_10.Opacity = 1;
        SLChangeURL(AktuelleVodPosition);
        FlagLiveRunning = false;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_VOD_Film_11: function(sender, eventArgs) {
        AktuelleVodPosition = 1;
        this._setzeblendeVod(sender, eventArgs);
        this.vbildblende_11.Opacity = 1;
        SLChangeURL(AktuelleVodPosition);
        FlagLiveRunning = false;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_VOD_Film_12: function(sender, eventArgs) {
        AktuelleVodPosition = 2;
        this._setzeblendeVod(sender, eventArgs);
        this.vbildblende_12.Opacity = 1;
        SLChangeURL(AktuelleVodPosition);
        FlagLiveRunning = false;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_VOD_Film_13: function(sender, eventArgs) {
        AktuelleVodPosition = 3;
        this._setzeblendeVod(sender, eventArgs);
        this.vbildblende_13.Opacity = 1;
        SLChangeURL(AktuelleVodPosition);
        FlagLiveRunning = false;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_VOD_Film_14: function(sender, eventArgs) {
        AktuelleVodPosition = 4;
        this._setzeblendeVod(sender, eventArgs);
        this.vbildblende_14.Opacity = 1;
        SLChangeURL(AktuelleVodPosition);
        FlagLiveRunning = false;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_VOD_Film_15: function(sender, eventArgs) {
        AktuelleVodPosition = 5;
        this._setzeblendeVod(sender, eventArgs);
        this.vbildblende_15.Opacity = 1;
        SLChangeURL(AktuelleVodPosition);
        FlagLiveRunning = false;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_VOD_Film_16: function(sender, eventArgs) {
        AktuelleVodPosition = 6;
        this._setzeblendeVod(sender, eventArgs);
        this.vbildblende_16.Opacity = 1;
        SLChangeURL(AktuelleVodPosition);
        FlagLiveRunning = false;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_VOD_Film_17: function(sender, eventArgs) {
        AktuelleVodPosition = 7;
        this._setzeblendeVod(sender, eventArgs);
        this.vbildblende_17.Opacity = 1;
        SLChangeURL(AktuelleVodPosition);
        FlagLiveRunning = false;
        //this.StoryepgRightSlide.begin();
    },
    // Magazine öffnen

    // sender, eventArgs  _Starte_Magazin

    _setzeblendeMag: function(sender, eventArgs) {

        // Alle Blenden einschalten
        this.vbildblende_20.Opacity = 0.3;
        this.vbildblende_21.Opacity = 0.3;
        this.vbildblende_22.Opacity = 0.3;
        this.vbildblende_23.Opacity = 0.3;
        this.vbildblende_24.Opacity = 0.3;
        this.vbildblende_25.Opacity = 0.3;
        this.vbildblende_26.Opacity = 0.3;
        this.vbildblende_27.Opacity = 0.3;

        // Blende des laufenden Film öffnen
        switch (AktuelleMagPosition) {
            case 0: this.vbildblende_20.Opacity = 1; break;
            case 1: this.vbildblende_21.Opacity = 1; break;
            case 2: this.vbildblende_22.Opacity = 1; break;
            case 3: this.vbildblende_23.Opacity = 1; break;
            case 4: this.vbildblende_24.Opacity = 1; break;
            case 5: this.vbildblende_25.Opacity = 1; break;
            case 6: this.vbildblende_26.Opacity = 1; break;
            case 7: this.vbildblende_27.Opacity = 1; break;
        }

    },

    _Starte_Magazin_20: function(sender, eventArgs) {
        if (AktuelleMagPosition == -1) { this.StorySlideOutModblende.begin(); }
        AktuelleMagPosition = 0;
        //this.vbildblende_20.Opacity = 1; 
        SLChangeMagURL(AktuelleMagPosition);
        this._setzeblendeMag(sender, eventArgs);

        FlagLiveRunning = false;
        FlagMagRunning = true;

        //this.StoryepgRightSlide.begin();
    },
    _Starte_Magazin_21: function(sender, eventArgs) {
        if (AktuelleMagPosition == -1) { this.StorySlideOutModblende.begin(); }
        AktuelleMagPosition = 1;

        //this.vbildblende_21.Opacity = 1; 
        SLChangeMagURL(AktuelleMagPosition);
        this._setzeblendeMag(sender, eventArgs);
        FlagLiveRunning = false;
        FlagMagRunning = true;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_Magazin_22: function(sender, eventArgs) {
        if (AktuelleMagPosition == -1) { this.StorySlideOutModblende.begin(); }
        AktuelleMagPosition = 2;
        this._setzeblendeMag(sender, eventArgs);
        this.vbildblende_22.Opacity = 1;
        SLChangeMagURL(AktuelleMagPosition);
        FlagLiveRunning = false;
        FlagMagRunning = true;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_Magazin_23: function(sender, eventArgs) {
        if (AktuelleMagPosition == -1) { this.StorySlideOutModblende.begin(); }
        AktuelleMagPosition = 3;
        this._setzeblendeMag(sender, eventArgs);
        this.vbildblende_23.Opacity = 1;
        SLChangeMagURL(AktuelleMagPosition);
        FlagLiveRunning = false;
        FlagMagRunning = true;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_Magazin_24: function(sender, eventArgs) {
        if (AktuelleMagPosition == -1) { this.StorySlideOutModblende.begin(); }
        AktuelleMagPosition = 4;
        this._setzeblendeMag(sender, eventArgs);
        this.vbildblende_24.Opacity = 1;
        SLChangeMagURL(AktuelleMagPosition);
        FlagLiveRunning = false;
        FlagMagRunning = true;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_Magazin_25: function(sender, eventArgs) {
        if (AktuelleMagPosition == -1) { this.StorySlideOutModblende.begin(); }
        AktuelleMagPosition = 5;
        this._setzeblendeMag(sender, eventArgs);
        this.vbildblende_25.Opacity = 1;
        SLChangeMagURL(AktuelleMagPosition);
        FlagLiveRunning = false;
        FlagMagRunning = true;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_Magazin_26: function(sender, eventArgs) {
        if (AktuelleMagPosition == -1) { this.StorySlideOutModblende.begin(); }
        AktuelleMagPosition = 6;
        this._setzeblendeMag(sender, eventArgs);
        this.vbildblende_26.Opacity = 1;
        SLChangeMagURL(AktuelleMagPosition);
        FlagLiveRunning = false;
        FlagMagRunning = true;
        //this.StoryepgRightSlide.begin();
    },
    _Starte_Magazin_27: function(sender, eventArgs) {
        if (AktuelleMagPosition == -1) { this.StorySlideOutModblende.begin(); }
        AktuelleMagPosition = 7;
        this._setzeblendeMag(sender, eventArgs);
        this.vbildblende_27.Opacity = 1;
        SLChangeMagURL(AktuelleMagPosition);
        FlagLiveRunning = false;
        FlagMagRunning = true;
        //this.StoryepgRightSlide.begin();
    },


    // sender, eventArgs  _Starte_VOD_Film


    _Starte_Magazin_Film: function(sender, eventArgs) {
        //alert("-position:"+ AktuelleMagPosition);
        //SLChangeURL( SLC_Vlink_20);
        FlagLiveRunning = false;
        //this.StoryepgRightSlide.begin();

    },



    //	_Starte_mag_Film_20: function(sender, eventArgs) {
    //		SLChangeURL( SLC_Vlink_20);
    //		FlagLiveRunning = false;
    //		//this.StoryepgRightSlide.begin();
    //	},	
    //	_Starte_mag_Film_21: function(sender, eventArgs) {
    //		SLChangeURL( SLC_Vlink_21);
    //		FlagLiveRunning = false;
    //		//this.StoryepgRightSlide.begin();
    //	},	
    //	_Starte_mag_Film_22: function(sender, eventArgs) {
    //		SLChangeURL( SLC_Vlink_22);
    //		FlagLiveRunning = false;
    //		//this.StoryepgRightSlide.begin();
    //	},		
    //	_Starte_mag_Film_23: function(sender, eventArgs) {
    //		SLChangeURL( SLC_Vlink_23);
    //		FlagLiveRunning = false;
    //		//this.StoryepgRightSlide.begin();
    //	},	
    //	_Starte_mag_Film_24: function(sender, eventArgs) {
    //		SLChangeURL( SLC_Vlink_24);
    //		FlagLiveRunning = false;
    //		//this.StoryepgRightSlide.begin();
    //	},		
    //	_Starte_mag_Film_25: function(sender, eventArgs) {
    //		SLChangeURL( SLC_Vlink_25);
    //		FlagLiveRunning = false;
    //		//this.StoryepgRightSlide.begin();
    //	},	
    //	_Starte_mag_Film_26: function(sender, eventArgs) {
    //		SLChangeURL( SLC_Vlink_26);
    //		FlagLiveRunning = false;
    //		//this.StoryepgRightSlide.begin();
    //	},	
    //	_Starte_mag_Film_27: function(sender, eventArgs) {
    //		SLChangeURL( SLC_Vlink_27);
    //		FlagLiveRunning = false;
    //		//this.StoryepgRightSlide.begin();
    //	},	



    // End Magazin
    // Leftslide     rechter Knopf
    _ButtChapterArea_ScrollNext: function() {
        if (IndexShiftLive < MaxShift_Live) {		//alert("-");
            if (Linkslauf_Live == false) { Richtungswechsel_Live = true; }
            Linkslauf_Live = true;
            if (!Richtungswechsel_Live) { xml_daten_eintragen(); }  // bei einem Richtungswechsel wird nur die Buene verschoben
            IndexShiftLive++;
            this.StoryepgLeftSlide.begin();
            Richtungswechsel_Live = false;

        }
    },
    // Rightslide     linker Knopf
    _ButtChapterArea_ScrollPrevious: function() { //alert ( "ButtChapterArea_ScrollPrevious-Linkslauf_Live-"+Linkslauf_Live+"-Richtungswechsel_Live-"+ Richtungswechsel_Live);

        if (IndexShiftLive > 0) {
            if (Linkslauf_Live == true) { Richtungswechsel_Live = true; }
            Linkslauf_Live = false;
            IndexShiftLive--;
            if (!Richtungswechsel_Live) { xml_daten_eintragen(); Richtungswechsel_Live = false; }
            // Bei einem Richtungswechsel von links nach rechts wird nur die Bühne verschoben
            this.StoryepgRightSlide.begin();
            Richtungswechsel_Live = false;

        }
    },
    _ButtChapterArea_ScrollNext_vod: function() { //alert("--");

        if (IndexShiftVod < (MaxShift_Vod + 1)) {
            if (Linkslauf_Vod == false) { Richtungswechsel_Vod = true; }
            Linkslauf_Vod = true;
            //Richtungswechsel_Vod = false;	
            if (!Richtungswechsel_Vod) { xml_daten_eintragen_VOD(); }
            IndexShiftVod++;
            this.StoryepgvodLeftSlide.begin();

            //this.StoryepgRightSlide.begin();
            Richtungswechsel_Vod = false;
        }
    },
    _ButtChapterArea_ScrollPrevious_vod: function() {

        if (IndexShiftVod > 0) {
            if (Linkslauf_Vod == true) { Richtungswechsel_Vod = true; }

            Linkslauf_Vod = false; IndexShiftVod--;
            if (!Richtungswechsel_Vod) { xml_daten_eintragen_VOD(); }  // bei einem Richtungswechsel wird nur die Buene verschoben
            this.StoryepgvodRightSlide.begin();
            Richtungswechsel_Vod = false;

            //this.StoryepgLeftSlide.begin();
        }
    },
    _ButtChapterArea_ScrollNext_mag: function() {
        if (IndexShiftMag < MaxShift_Mag + 1) {
            if (Linkslauf_Mag == false) { Richtungswechsel_Mag = true; }
            Linkslauf_Mag = true;
            //Richtungswechsel_Vod = false;	
            if (!Richtungswechsel_Mag) { xml_daten_eintragen_mag(); }
            IndexShiftMag++;
            this.StoryepgmagLeftSlide.begin();
            Richtungswechsel_Mag = false;
            //this.StoryepgRightSlide.begin();
        }
    },
    _ButtChapterArea_ScrollPrevious_mag: function() {
        if (IndexShiftMag > 0) {
            if (Linkslauf_Mag == true) { Richtungswechsel_Mag = true; }
            IndexShiftMag--;
            Linkslauf_Mag = false;
            if (!Richtungswechsel_Vod) { xml_daten_eintragen_mag(); }  // bei einem Richtungswechsel wird nur die Buene verschoben


            this.StoryepgmagRightSlide.begin();
            Richtungswechsel_Mag = false;
            //this.StoryepgLeftSlide.begin();
        }
    }
    //	_FuscreenButtonMouseEnter: function() {
    // 		this.FuscreenButtonObj.Opacity = 1;
    //	},
    //	_FuscreenButtonMouseLeave: function() {
    // 		this.FuscreenButtonObj.Opacity = 0.5;
    //	}	

}

