Skip to content

Conversation

@tarrinneal
Copy link
Contributor

Since the newest Android image picker doesn't yet support cloud files, I've moved it to an optional parameter for now.
This will allow users to maintain their cloud access while still allowing the people who want to use the new picker to do so as well.

fixes flutter/flutter#121744

If you had to change anything in the flutter/tests repo, include a link to the migration guide as per the breaking change policy.

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read and followed the relevant style guides and ran the auto-formatter. (Unlike the flutter/flutter repo, the flutter/packages repo does use dart format.)
  • I signed the CLA.
  • The title of the PR starts with the name of the package surrounded by square brackets, e.g. [shared_preferences]
  • I listed at least one issue that this PR fixes in the description above.
  • I updated pubspec.yaml with an appropriate new version according to the pub versioning philosophy, or this PR is exempt from version changes.
  • I updated CHANGELOG.md to add a description of the change, following repository CHANGELOG style.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or this PR is test-exempt.
  • All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel on Discord.

Copy link
Collaborator

@stuartmorgan-g stuartmorgan-g left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rather than have this Android-specific option in all of the APIs, I would rather we restrict this to the Android package. Since I doubt anyone is going to want different versions for different calls within the same app, the simplest option for clients would be a class-level setting, which we can put on the Android implementation in this case.

See https://pub.dev/packages/google_maps_flutter_android#display-mode for an example of what a platform class option looks like.

@tarrinneal
Copy link
Contributor Author

Rather than have this Android-specific option in all of the APIs, I would rather we restrict this to the Android package. Since I doubt anyone is going to want different versions for different calls within the same app, the simplest option for clients would be a class-level setting, which we can put on the Android implementation in this case.

See https://pub.dev/packages/google_maps_flutter_android#display-mode for an example of what a platform class option looks like.

This is very helpful, thank you

Copy link
Collaborator

@stuartmorgan-g stuartmorgan-g left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, this looks good at the Android package level. I left a comment about the wrapper API in the app-facing package, which we should remove. I apparently picked the worst example to point you to without realizing it :(

Unfortunately the implementation-package-specific APIs are still relatively new territory in our plugin development, so things aren't as consistent as they could be yet.

@tarrinneal tarrinneal marked this pull request as ready for review March 8, 2023 01:15
@tarrinneal tarrinneal requested a review from gmackall as a code owner March 8, 2023 01:15
Copy link
Collaborator

@stuartmorgan-g stuartmorgan-g left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with some nits on the README.

@tarrinneal tarrinneal added the autosubmit Merge PR when tree becomes green via auto submit App label Mar 9, 2023
@auto-submit auto-submit bot merged commit 3814ec4 into flutter:main Mar 9, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Mar 9, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Mar 9, 2023
nploi pushed a commit to nploi/packages that referenced this pull request Jul 16, 2023
[image_picker] moves Android 13 image picker to options
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

autosubmit Merge PR when tree becomes green via auto submit App p: image_picker platform-android

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[image_picker] No longer able to select photos from Google Photos

3 participants