geolocator_watchos 0.1.1
geolocator_watchos: ^0.1.1 copied to clipboard
watchOS implementation of the geolocator plugin, providing position and permission handling from CoreLocation (CLLocationManager) via dart:ffi.
0.1.1 #
- README: the install snippet names
geolocator: ^14.1.1and this version. It named^0.0.1, which does not admit 0.1.x. pubspec.yaml:repositorypoints at this package's folder in the plugins repo.- Comments now say what keeps the FFI exports in the app: the CLI force-loads
the plugin archive, each export is
usedwith default visibility, and the CLI keeps global symbols through the App Store strip.ffiSymbolslists the exports. - README: a "Not supported on watchOS" table; PORTING_REPORT: an "Interface
coverage" list of every member of
geolocator_platform_interface4.4.0, audited by hand. - Dartdoc on every public member, and
public_member_api_docsis on inanalysis_options.yaml. - Example:
pubspec.yamlnamesgeolocator: ^14.1.1instead ofany.
0.1.0 #
First release beyond the generated scaffold.
Breaking
pollIntervalis gone, replaced bypermissionTimeout(default 2 minutes), which bounds the wait for the system permission prompt rather than setting a polling rate.- Minimum Dart SDK is now 3.1.0, where
NativeCallable.listenerlanded.
Changed
getPositionStream,getCurrentPositionandrequestPermissionare all pushed from CoreLocation delegate callbacks. No polling remains.- Added a
locationManagerDidChangeAuthorization:delegate method: the answer to a permission prompt arrives there and nowhere else, so waiting on it is the only way to observe it without polling. didFailWithErrornow wakes a waiter, which re-checks rather than sitting until its deadline.
Fixed
- The three callers that can wait concurrently — a position stream, a pending
getCurrentPosition, a pendingrequestPermission— now share one native callback. The native side holds a single callback pointer, so registering per caller let whichever finished first silence the others. - The shared
NativeCallableis now reused across listen/cancel cycles instead of being discarded when the last waiter left. ANativeCallableis only reclaimed byclose(), which is exactly what cannot be called while native might be between reading the pointer and calling it — so the old code leaked one trampoline per cycle for the life of the app. Only the pointer is unregistered now.
0.0.1 #
- Initial watchOS FFI scaffold generated by
flutter-watchos plugin portfromgeolocator_apple.