sarbagyastha / youtube_player_flutter

A Flutter plugin for inline playback or streaming of YouTube videos using the official iFrame Player API.
https://youtube.sarbagyastha.com.np
BSD 3-Clause "New" or "Revised" License
692 stars 785 forks source link

[iFrame package] dispose method for controller? #345

Open jimmyff opened 4 years ago

jimmyff commented 4 years ago

YoutubePlayerController has no .dispose() method

shinyford commented 4 years ago

It does have a dispose method, FWIW - at least, on device. (Haven't tried it on web.)

jimmyff commented 4 years ago

Screenshot 2020-08-27 at 13 25 09

There is a .close() method, but I don't see a .dispose()?

jimmyff commented 4 years ago

Here is the source to confirm no dispose: https://github.com/sarbagyastha/youtube_player_flutter/blob/master/packages/youtube_player_iframe/lib/src/controller.dart

I think close() is in place of dispose(), but it breaks the usual flutter convention.

shinyford commented 4 years ago

Ah! My mistake: I was looking at the youtube_player_flutter package, for which the controller does have a dispose method. You're looking at the youtube_player_iframe dependency.