private void OnTvVideo(object obj) { if (this.InnerController.CurrentVM is MultimediaViewModel) { this.multimediaVisualState = (this.InnerController.CurrentVM as MultimediaViewModel).GetVisualState(); } if (!(this.InnerController.CurrentVM is TvVideoViewModel)) { this.InnerController.Navigate(new TvVideoViewModel(this.deviceController, this.TargetDevice), true); } }
private void OnRemoteControl(object obj) { if (this.InnerController.CurrentVM is MultimediaViewModel) { this.multimediaVisualState = (this.InnerController.CurrentVM as MultimediaViewModel).GetVisualState(); } if (!(this.InnerController.CurrentVM is RemoteControlViewModel)) { this.InnerController.Navigate(new RemoteControlViewModel(this.TargetDevice, this.deviceController, base.Controller), true); } }
public MultimediaNowPlayingViewModel(SavedMultimediaVisualState vs, IMultiScreen multiScreen) { this.multiScreen = multiScreen; this.multiScreen.MultiscreenQueueUpdated += new EventHandler(this.multiScreen_MultiscreenQueueUpdated); this.multiScreen.MultiscreenCurrentMediaContentUpdated += new EventHandler(this.multiScreen_MultiscreenCurrentMediaContentUpdated); this.vs = vs; this.playPreviousFile = new UICommand(new Action <object>(this.OnPlayPreviousFile), new Predicate <object>(this.HasCurrentMediaContentDuration)); this.play = new UICommand(new Action <object>(this.OnPlay), new Predicate <object>(this.IsCurrentMediaContentEmpty)); this.pause = new UICommand(new Action <object>(this.OnPause), new Predicate <object>(this.IsCurrentMediaContentEmpty)); this.playNextFile = new UICommand(new Action <object>(this.OnPlayNextFile), null); this.changePosition = new UICommand(new Action <object>(this.OnChangePosition), new Predicate <object>(this.HasCurrentMediaContentDuration)); this.playOrPause = new UICommand(new Action <object>(this.OnPlayOrPause), new Predicate <object>(this.IsCurrentMediaContentEmpty)); }