private void VideoDidFinishPlaying(NSNotification obj) { OnFinishedPlaying?.Invoke(); Console.WriteLine("Video Finished, will now restart"); Player.Seek(new CMTime(0, 1)); Stop(); }
private void MediaPlayer_Completion(object sender, EventArgs e) { OnFinishedPlaying?.Invoke(); if (_mediaPlayer != null) { IsPlaying = _mediaPlayer.IsPlaying; } }
private void Player_FinishedPlaying(object sender, AVStatusEventArgs e) { OnFinishedPlaying?.Invoke(); if (_audioPlayer != null) { _audioPlayer.CurrentTime = 0; } }
public virtual void FinishedUsing(bool countered = false) { if (!countered) { if (finishedEffects == null) { finishedEffects = new List <CommonEffect> (); } if (interceptFinishCard) { interceptFinishCard.InterceptFinish(); return; } foreach (CommonEffect c in commonEffects) { if (!finishedEffects.Contains(c)) { CurrentEffect = c; MethodInfo mi = typeof(SC_BaseCard).GetMethod(c.effectType.ToString() + "Finished"); if (mi != null) { finishedEffects.Add(c); mi.Invoke(this, null); return; } } } } if (OnFinishedPlaying != null && OnFinishedPlaying.GetInvocationList().Length > 0) { OnFinishedPlaying.Invoke(); return; } BaseFinishedUsing(); }
void MediaPlayer_Completion(object sender, EventArgs e) { OnFinishedPlaying?.Invoke(); IsStoped = true; IsCompleted = true; }
private void Player_FinishedPlaying(object sender, AVStatusEventArgs e) { //TODO: restart player so it keeps looping? // is there a better way? can we just set it to loop to begin with? OnFinishedPlaying?.Invoke(); }
void MediaPlayer_Completion(object sender, EventArgs e) { OnFinishedPlaying?.Invoke(); _mediaPlayer.SeekTo(0); }