private void OnVideoEnd(CgDataItem cgDataItem) { BaseMonoCanvas mainCanvas = Singleton <MainUIManager> .Instance.GetMainCanvas(); if (mainCanvas != null) { MonoMainCanvas canvas2 = mainCanvas as MonoMainCanvas; if (canvas2 != null) { this.SetStarEffectActive(true); } } }
private void HandleSpaceShip() { if (this.showSpaceShip) { MonoMainCanvas mainCanvas = Singleton <MainUIManager> .Instance.GetMainCanvas() as MonoMainCanvas; if (mainCanvas != null) { mainCanvas.InitMainPageContexts(); } } Singleton <NotifyManager> .Instance.FireNotify(new Notify(NotifyTypes.SetSpaceShipActive, new Tuple <bool, bool>(this.showSpaceShip, false))); Singleton <NotifyManager> .Instance.FireNotify(new Notify(NotifyTypes.SetSpaceShipLight, base.config.contextName == "MainPageContext")); }
public override void Destroy() { base.Destroy(); BaseMonoCanvas mainCanvas = Singleton <MainUIManager> .Instance.GetMainCanvas(); if (mainCanvas != null) { MonoMainCanvas canvas2 = mainCanvas as MonoMainCanvas; if (canvas2 != null) { MonoVideoPlayer videoPlayer = canvas2.VideoPlayer; videoPlayer.OnVideoEnd = (Action <CgDataItem>)Delegate.Remove(videoPlayer.OnVideoEnd, new Action <CgDataItem>(this.OnVideoBegin)); MonoVideoPlayer player2 = canvas2.VideoPlayer; player2.OnVideoEnd = (Action <CgDataItem>)Delegate.Remove(player2.OnVideoEnd, new Action <CgDataItem>(this.OnVideoEnd)); } } }