Tags: flutter/packages
Tags
[google_maps_flutter_platform_interface] Add onPointOfInterestTap sup… …port (#12752) This is the platform interface portion of #11872 Adds `PointOfInterestId`, `PointOfInterestTapEvent`, and `GoogleMapsFlutterPlatform.onPointOfInterestTap`. The default implementation returns an empty stream so existing platform implementations are not broken. Fixes flutter/flutter#60695 (platform interface only; app-facing and implementation packages land in follow-up PRs per the federated plugin contribution process). ## Pre-Review Checklist @stuartmorgan-g — this is the first sub-PR from #11872 as requested.
[google_maps_flutter] Adopts new async/await Swift Pigeon support (#1… …2860) Switches from the callback-based Pigeon API to the new async/await-based API, which is: - more idiomatic modern Swift - safer, both since it uses Pigeon-generated actor annotations to ensure proper threading, and because it prevents the error case of calling the callback some number of times other than exactly once (which violates the engine API contract) - the syntax used by the new FFI backend that we plan to switch to in a follow-up I verified that with this version of Pigeon we are no longer seeing thread violation logging in manual testing (see flutter/flutter#192199) There is some extra `Task` boilerplate in many callbacks still because we are implementing APIs that are defined by the Google Maps API, and those are not yet using `async` and actor annotations, so we have to bridge them in the plugin layer. Part of flutter/flutter#192720 ## 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.
[google_maps_flutter] Adopts new async/await Swift Pigeon support (#1… …2860) Switches from the callback-based Pigeon API to the new async/await-based API, which is: - more idiomatic modern Swift - safer, both since it uses Pigeon-generated actor annotations to ensure proper threading, and because it prevents the error case of calling the callback some number of times other than exactly once (which violates the engine API contract) - the syntax used by the new FFI backend that we plan to switch to in a follow-up I verified that with this version of Pigeon we are no longer seeing thread violation logging in manual testing (see flutter/flutter#192199) There is some extra `Task` boilerplate in many callbacks still because we are implementing APIs that are defined by the Google Maps API, and those are not yet using `async` and actor annotations, so we have to bridge them in the plugin layer. Part of flutter/flutter#192720 ## 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.
[google_maps_flutter] Convert remaining code to Swift (#12768) Converts remaining code to Swift: - Converts the protocols defined for testability to Swift - Where possible, replaces manual passthrough classes with extensions that add protocol conformance to the actual class, reducing the amount of untestable code we need. - Switches Pigeon generation to Swift (which causes a lot of mechanical changes due to classes no longer having a prefix, and the constructors being standard Swift construction instead of bridging to Obj-C convenience constructors) - Uses Pigeon's Swift generator support for subclassing to replace the somewhat hacky nested classes in the interface definition with the actual subclassing that we wanted to express, simplifying some code and adding more type safety. - Scrubs `NSObject` conformance from cases where it's no longer necessary. (Class that implement Flutter plugin API protocols still need it, as those are Obj-C protocols.) Unlike the other PRs, this does not contain any Gemini Obj-C -> Swift conversions (other than some simple protocols); this is mostly just a Pigeon generation change and a lot of mostly mechanical cleanup. Fixes flutter/flutter#119108 ## 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.
[google_maps_flutter] Convert remaining code to Swift (#12768) Converts remaining code to Swift: - Converts the protocols defined for testability to Swift - Where possible, replaces manual passthrough classes with extensions that add protocol conformance to the actual class, reducing the amount of untestable code we need. - Switches Pigeon generation to Swift (which causes a lot of mechanical changes due to classes no longer having a prefix, and the constructors being standard Swift construction instead of bridging to Obj-C convenience constructors) - Uses Pigeon's Swift generator support for subclassing to replace the somewhat hacky nested classes in the interface definition with the actual subclassing that we wanted to express, simplifying some code and adding more type safety. - Scrubs `NSObject` conformance from cases where it's no longer necessary. (Class that implement Flutter plugin API protocols still need it, as those are Obj-C protocols.) Unlike the other PRs, this does not contain any Gemini Obj-C -> Swift conversions (other than some simple protocols); this is mostly just a Pigeon generation change and a lot of mostly mechanical cleanup. Fixes flutter/flutter#119108 ## 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.
[pigeon] main actor async flutter api (#12729) adds main actor annotation to async flutter api methods in swift. fixes flutter/flutter#192199
[pigeon] Add FFI and JNI support to Swift and Kotlin (#11352) This PR introduces optional Native Interop to Pigeon, enabling direct communication between Dart and native code without the overhead of traditional MethodChannel serialization. It leverages FFI (Foreign Function Interface) for Swift (iOS/macOS) and JNI (Java Native Interface) for Kotlin (Android). This represents a significant architectural shift, moving from message-based passing to direct memory sharing and function calls. It also updates the concurrency model for asynchronous methods, moving from completion handlers/callbacks to modern language features: async/await in Swift and Coroutines in Kotlin. Generators Covered Swift Generator: Updated to support FFI bindings and async/await for asynchronous methods. Kotlin Generator: Updated to support JNI bindings and Kotlin Coroutines for asynchronous methods. Dart Generator: Updated to handle the generated interop bindings on the Dart side. What's In Scope 1. Infrastructure: Added core support for useFfi and useJni options. 2. Automation: Implemented multi-step generation flows that automatically invoke jnigen and ffigen to produce final bindings. 3. Config Generation: Added jnigen_config_generator.dart and ffigen_config_generator.dart to generate the necessary configuration files for the external tools. 4. Documentation: Added a detailed native_interop_guide.md explaining prerequisites, setup, and usage. Tests: Added ni_tests.dart and associated generated files and integration tests to verify the feature. What's Out of Scope 1. Other Languages: This PR specifically targets Swift and Kotlin for the Native Interop feature. Support for Objective-C, C++, and GObject is not included in this interop implementation, and may not be in the future. 2. Performance Optimization for Complex Classes: As noted in the guide, there is a known performance regression when transferring complex classes with many fields compared to MethodChannel Pigeon. This PR delivers the functional infrastructure, but optimizing this specific case is left for follow-up work. 3. Non-instant released data. Currently all data that is sent over host or flutter api surfaces is converted to the correct shape and type for the language it is moving toward and the data created in the other language is then discarded. This presents some inefficiencies and potential workflows that are not yet available. work toward flutter/flutter#182230 design doc flutter/flutter#181430
[in_app_purchase_storekit] Expose expiration date directly for subscr… …iptions (#11551) Fixes a potential cause of flutter/flutter#181530 Quite a few IAP bugs seem to be surrounding stale data, so expose the expiration date directly to have to avoid doing local receipt shenanigans. ## Pre-Review Checklist
[image_picker] Handle a null stream from openInputStream (#12718) Null safety when ContentResolver cannot open a stream. Copied from closed: #12682 Fixes: flutter/flutter#191988 ## Pre-Review Checklist
PreviousNext