public void FullScreen() { if (!IsFullscreenDisabled) { VideoSubPanel.SetFullScreen(true); } }
public void PlayVideo(MediaItem media) { // Sanity, video should be enabled. Audio disabled. VideoContainer.gameObject.SetActive(true); AudioContainer.gameObject.SetActive(false); VideoContainer.SetFullScreen(UseFullScreen); // Pass the ref to video controls so that it can rotate the video. if (VideoContainer.FullScreen) { VideoContainer.FullScreen.GetComponentInChildren <VideoControls>().VideoSubpanel = VideoContainer; } VideoContainer.Play(media, () => { VideoContainer.SetFullScreen(UseFullScreen); }); m_videoControlsPushedPanel = VideoControlsTarget.PushPanel(VideoControls) as ControlsPanel; if (m_videoControlsPushedPanel == null) { return; } // Set the controls to on and disable the audio control functionality of the controls object. m_videoControlsPushedPanel.gameObject.SetActive(true); m_videoControlsPushedPanel.Disable(typeof(AudioSubpanel)); if (!VideoContainer.FullScreen) { m_videoControlsPushedPanel.DisableFullScreen(); } // HACK: toggle to get audio playing. Fix this asap. VideoContainer.gameObject.SetActive(false); VideoContainer.gameObject.SetActive(true); }
public void ExitFullScreen() { VideoSubpanel.SetFullScreen(false); }
public override void Populate(MediaContent data) { VideoSubpanel.SetFullScreen(UseFullScreen); VideoSubpanel.Play(data.MediaItem); }