mirror of
https://github.com/tommyxchow/frosty.git
synced 2025-08-06 08:51:29 +08:00
Fix video not loading on iOS
Looks like Twitch made some updates to their mobile player on iOS where it will first navigate to a bunch of URLs (probably related to ads or analytics based on the domains). This resulted in the `NavigationDelegate` not picking this up and preventing the loading by default. To fix, I've just removed the `NavigationDelegate` because it's legacy code that really isn't needed anymore.
This commit is contained in:
@ -54,13 +54,6 @@ abstract class VideoStoreBase with Store {
|
||||
..setNavigationDelegate(
|
||||
NavigationDelegate(
|
||||
onPageFinished: (_) => initVideo(),
|
||||
// Used for preventing accidental navigation in the webview.
|
||||
onNavigationRequest: (request) {
|
||||
if (request.url.startsWith('https://player.twitch.tv')) {
|
||||
return NavigationDecision.navigate;
|
||||
}
|
||||
return NavigationDecision.prevent;
|
||||
},
|
||||
),
|
||||
)
|
||||
..loadRequest(Uri.parse(videoUrl));
|
||||
|
Reference in New Issue
Block a user