From 2558182b6faf7a722baa49a2ab6a0082c2a253b6 Mon Sep 17 00:00:00 2001 From: jerrry08 Date: Mon, 6 Nov 2023 10:52:24 -0400 Subject: [PATCH] Re-initialize exoplayer --- .../Videos/Controller/PlatformMediaController.android.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/AniStream/ViewModels/Videos/Controller/PlatformMediaController.android.cs b/AniStream/ViewModels/Videos/Controller/PlatformMediaController.android.cs index 57901ff..058ff09 100644 --- a/AniStream/ViewModels/Videos/Controller/PlatformMediaController.android.cs +++ b/AniStream/ViewModels/Videos/Controller/PlatformMediaController.android.cs @@ -151,6 +151,11 @@ public void UpdateSourceInfo() episodeTitle.Text = Episode.Name; SetNextAndPrev(); + + var handler = (MediaElementHandler)MediaElement.Handler; + playerView = handler.PlatformView.GetFirstChildOfType()!; + exoPlayer = (IExoPlayer)playerView.Player; + exoPlayer.AddListener(this); } #region Setup