-
Notifications
You must be signed in to change notification settings - Fork 3.4k
[camera,video_player] replace onSurfaceDestroyed with onSurfaceCleanup #9316
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
[camera,video_player] replace onSurfaceDestroyed with onSurfaceCleanup #9316
Conversation
@matanlurey Have I correctly understood that we no longer need all the save/restore, as discussed in the issue thread? A quick manual test suggests that it works, but I don't know if there were more subtle problems that led to the save/restore approach. |
The (implicit - Dart SDK bump) formatter rev makes this harder to review - would you consider doing that in a first PR? |
|
This is a prequel to #9316 to separate out auto-generated changes. All this does is: - Set the minimum SDK version to 3.29. - Run the autoformatter—which changes a ton of things because the 3.29 minimum opts into the new formatter. ## Pre-Review Checklist [^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
Rebased; the Dart changes are gone. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the cleanup! LGTM!
/cc @camsim99
flutter/packages@af0b9a9...6eebe72 2025-05-27 github@benprice.ca [flutter_lints] Bump lints dependency to 6.0.0 and bump package to 6.0.0 (flutter/packages#9108) 2025-05-26 engine-flutter-autoroll@skia.org Roll Flutter from 60050a0 to 4372bfb (6 revisions) (flutter/packages#9322) 2025-05-26 robert.odrowaz@leancode.pl [video_player_android] Add note about Android platform views known issue (flutter/packages#9312) 2025-05-24 engine-flutter-autoroll@skia.org Roll Flutter from 85564cb to 60050a0 (17 revisions) (flutter/packages#9318) 2025-05-23 43054281+camsim99@users.noreply.github.com [camera_android_camerax] Implement `enableAudio` for video recording (flutter/packages#9264) 2025-05-23 65381000+raju-muliyashiya@users.noreply.github.com [video_player_android] isBuffering flag always return true after calling seekTo method - fixed (flutter/packages#9198) 2025-05-23 stuartmorgan@google.com [camera,video_player] replace onSurfaceDestroyed with onSurfaceCleanup (flutter/packages#9316) 2025-05-23 stuartmorgan@google.com [camera,video_player] Update Android to 3.29 minimum (flutter/packages#9317) 2025-05-23 engine-flutter-autoroll@skia.org Roll Flutter from 33cdd8e to 85564cb (39 revisions) (flutter/packages#9315) 2025-05-23 stuartmorgan@google.com Update repo for 3.32 stable (flutter/packages#9311) 2025-05-23 robert.odrowaz@leancode.pl [camera_avfoundation] Correct pigeon configuration output paths (flutter/packages#9313) 2025-05-23 stuartmorgan@google.com [process] Remove from the repository (flutter/packages#9310) 2025-05-22 jessiewong401@gmail.com Ensure Example Packages Work on Android API 36 (flutter/packages#9241) 2025-05-22 engine-flutter-autoroll@skia.org Roll Flutter (stable) from c236373 to be698c4 (1274 revisions) (flutter/packages#9300) 2025-05-22 magder@google.com Remove CODEOWNER for generated iOS files (flutter/packages#9272) 2025-05-22 52160996+FMorschel@users.noreply.github.com [google_maps_flutter] Removes unnecessary parentheses (flutter/packages#9273) 2025-05-21 magder@google.com Rebalance Android plugin CODEOWNERS (flutter/packages#9298) 2025-05-21 engine-flutter-autoroll@skia.org Roll Flutter from 9a78af5 to 33cdd8e (60 revisions) (flutter/packages#9305) 2025-05-21 stuartmorgan@google.com [ci] Update repository for 3.29 release (flutter/packages#9270) 2025-05-21 stuartmorgan@google.com Ignore .cxx/ directories (flutter/packages#9268) 2025-05-21 stuartmorgan@google.com [video_player] Skip some integration tests on web (flutter/packages#9302) 2025-05-21 10687576+bparrishMines@users.noreply.github.com [webview_flutter] Adds support to respond to recoverable SSL certificate errors (flutter/packages#9150) 2025-05-19 43054281+camsim99@users.noreply.github.com [camera_android_camerax] Swap out `BroadcastReceiver` for `OrientationEventListener` (flutter/packages#9261) 2025-05-19 54174311+marvin-kolja@users.noreply.github.com [video_player_android] Fix incorrect dimensions swap (flutter/packages#9199) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC flutter-ecosystem@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
This is a prequel to flutter#9316 to separate out auto-generated changes. All this does is: - Set the minimum SDK version to 3.29. - Run the autoformatter—which changes a ton of things because the 3.29 minimum opts into the new formatter. ## Pre-Review Checklist [^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
flutter#9316) Replaces deprecated `onSurfaceDestroyed` with `onSurfaceCleanup`, which became available in Flutter 3.29 (which these packages require as of flutter#9317). The changes to video player are non-trivial because rather than make the minimal change, this makes the changes discussed in flutter/flutter#160933 (comment) that motivated the change in API in the first place, which simplifies the handling of backgrounding, and restores background playback. Fixes flutter/flutter#161256 Fixes flutter/flutter#156936 ## Pre-Review Checklist [^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
This is a prequel to flutter#9316 to separate out auto-generated changes. All this does is: - Set the minimum SDK version to 3.29. - Run the autoformatter—which changes a ton of things because the 3.29 minimum opts into the new formatter. ## Pre-Review Checklist [^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
flutter#9316) Replaces deprecated `onSurfaceDestroyed` with `onSurfaceCleanup`, which became available in Flutter 3.29 (which these packages require as of flutter#9317). The changes to video player are non-trivial because rather than make the minimal change, this makes the changes discussed in flutter/flutter#160933 (comment) that motivated the change in API in the first place, which simplifies the handling of backgrounding, and restores background playback. Fixes flutter/flutter#161256 Fixes flutter/flutter#156936 ## Pre-Review Checklist [^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
Replaces deprecated
onSurfaceDestroyed
withonSurfaceCleanup
, which became available in Flutter 3.29 (which these packages require as of #9317).The changes to video player are non-trivial because rather than make the minimal change, this makes the changes discussed in flutter/flutter#160933 (comment) that motivated the change in API in the first place, which simplifies the handling of backgrounding, and restores background playback.
Fixes flutter/flutter#161256
Fixes flutter/flutter#156936
Pre-Review Checklist
[shared_preferences]
pubspec.yaml
with an appropriate new version according to the pub versioning philosophy, or I have commented below to indicate which version change exemption this PR falls under1.CHANGELOG.md
to add a description of the change, following repository CHANGELOG style, or I have commented below to indicate which CHANGELOG exemption this PR falls under1.///
).Footnotes
Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling. ↩ ↩2 ↩3