Uh oh!
There was an error while loading. Please reload this page.
[camera_avfoundation] Wrappers swift migration - part 2 - #10284
Conversation
There was a problem hiding this comment.
Code Review
This pull request continues the migration of the camera_avfoundation plugin from Objective-C to Swift by converting FLTCameraDeviceDiscovering and FLTDeviceOrientationProviding. The changes involve replacing Objective-C protocols and implementations with their Swift equivalents, updating call sites to use the new Swift types, and removing the now-obsolete Objective-C files. The new Swift code follows modern conventions, such as using computed properties instead of methods where appropriate. I've left one comment regarding a naming inconsistency for you to consider. Overall, this is a solid step forward in the migration process.
Uh oh!
There was an error while loading. Please reload this page.
8b8919e to
5615eb3CompareUh oh!
There was an error while loading. Please reload this page.
flutter/packages@53d6138...bbf96a0 2025-10-27 49699333+dependabot[bot]@users.noreply.github.com [dependabot]: Bump org.jetbrains.kotlin:kotlin-bom from 2.2.20 to 2.2.21 in /packages/pigeon/platform_tests/test_plugin/android (flutter/packages#10308) 2025-10-27 engine-flutter-autoroll@skia.org Roll Flutter from cb18290 to 4c91098 (9 revisions) (flutter/packages#10307) 2025-10-26 stuartmorgan@google.com [tool] Add validation of auto-labeler (flutter/packages#10300) 2025-10-24 stuartmorgan@google.com [ci] Auto-add triage labels for engine and framework (flutter/packages#10295) 2025-10-24 engine-flutter-autoroll@skia.org Roll Flutter from 75004a6 to cb18290 (48 revisions) (flutter/packages#10299) 2025-10-24 engine-flutter-autoroll@skia.org Roll Flutter (stable) from 9f455d2 to adc9010 (4 revisions) (flutter/packages#10292) 2025-10-24 robert.odrowaz@leancode.pl [camera_avfoundation] Wrappers swift migration - part 2 (flutter/packages#10284) 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
flutter/packages@53d6138...bbf96a0 2025-10-27 49699333+dependabot[bot]@users.noreply.github.com [dependabot]: Bump org.jetbrains.kotlin:kotlin-bom from 2.2.20 to 2.2.21 in /packages/pigeon/platform_tests/test_plugin/android (flutter/packages#10308) 2025-10-27 engine-flutter-autoroll@skia.org Roll Flutter from cb18290 to 4c91098 (9 revisions) (flutter/packages#10307) 2025-10-26 stuartmorgan@google.com [tool] Add validation of auto-labeler (flutter/packages#10300) 2025-10-24 stuartmorgan@google.com [ci] Auto-add triage labels for engine and framework (flutter/packages#10295) 2025-10-24 engine-flutter-autoroll@skia.org Roll Flutter from 75004a6 to cb18290 (48 revisions) (flutter/packages#10299) 2025-10-24 engine-flutter-autoroll@skia.org Roll Flutter (stable) from 9f455d2 to adc9010 (4 revisions) (flutter/packages#10292) 2025-10-24 robert.odrowaz@leancode.pl [camera_avfoundation] Wrappers swift migration - part 2 (flutter/packages#10284) 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
flutter/packages@53d6138...bbf96a0 2025-10-27 49699333+dependabot[bot]@users.noreply.github.com [dependabot]: Bump org.jetbrains.kotlin:kotlin-bom from 2.2.20 to 2.2.21 in /packages/pigeon/platform_tests/test_plugin/android (flutter/packages#10308) 2025-10-27 engine-flutter-autoroll@skia.org Roll Flutter from cb18290 to 4c91098 (9 revisions) (flutter/packages#10307) 2025-10-26 stuartmorgan@google.com [tool] Add validation of auto-labeler (flutter/packages#10300) 2025-10-24 stuartmorgan@google.com [ci] Auto-add triage labels for engine and framework (flutter/packages#10295) 2025-10-24 engine-flutter-autoroll@skia.org Roll Flutter from 75004a6 to cb18290 (48 revisions) (flutter/packages#10299) 2025-10-24 engine-flutter-autoroll@skia.org Roll Flutter (stable) from 9f455d2 to adc9010 (4 revisions) (flutter/packages#10292) 2025-10-24 robert.odrowaz@leancode.pl [camera_avfoundation] Wrappers swift migration - part 2 (flutter/packages#10284) 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
Migrates camera wrappers as part of flutter/flutter#119109 This PR migrates wrappers to Swift: * `FLTCameraDeviceDiscovering` * `FLTDeviceOrientationProviding` In line with Swift conventions, the `FLT` prefixes are removed. The `Default` class implementations are replaced with protocol conformance on base `AV` classes. ## Pre-Review Checklist **Note**: The Flutter team is currently trialing the use of [Gemini Code Assist for GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code). Comments from the `gemini-code-assist` bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed. [^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.
Migrates camera wrappers as part of flutter/flutter#119109
This PR migrates wrappers to Swift:
FLTCameraDeviceDiscoveringFLTDeviceOrientationProvidingIn line with Swift conventions, the
FLTprefixes are removed. TheDefaultclass implementations are replaced with protocol conformance on baseAVclasses.Pre-Review Checklist
[shared_preferences]pubspec.yamlwith 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.mdto add a description of the change, following repository CHANGELOG style, or I have commented below to indicate which CHANGELOG exemption this PR falls under1.///).If you need help, consider asking for advice on the #hackers-new channel on Discord.
Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the
gemini-code-assistbot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.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