-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FEATURE] Expose the eventListeners within the better_player_controller.dart file #584
Comments
pull request for feature is within #585 |
@Letalus I don't see any connection with exposing event listeners from |
hmm I guess I worded it badly. Due to the fact that I need to recycle the controllers, remove all the listeners and after the controller and its listeners have been recycled, initialize it again and add a new listener to it, I need to be able to tell if there are currently active listeners. By exposing the eventListeners, I'm able to do exactly that |
Okay, this will be included in next release. |
Added in 0.0.71. |
Feature:
Exposes all active eventListeners within the better_player_controller.dart file
Argument:
This functionality is useful when user are working with recycleController (controllers which will be reused after they have been disposed, or after the video has changed).
A good use case is if the user has a list of 100 videos within a pageviewer, creates 3 videoplayer, which then will be used to show all 100 videos (the pageviewer is always preloading the video before and after the current video).
This approach avoids within android the OOM Bug (because in android you can only create around 3 video player instances and after that the system won't let you create more)
Within iOS it is the same, except that you are able to create exactly 32 instances of the avplayer.
Conclusion:
By exposing the eventListeners, the developers are enabled to recycle the videos more efficiently
The text was updated successfully, but these errors were encountered: