INNER CODE UNIT · Dart
onAuthorization
transistorsoft/flutter_background_geolocation · lib/models/background_geolocation.dart:1711
static Subscription onAuthorization(Function(AuthorizationEvent) callback) {
if (_eventsAuthorization == null) {
_eventsAuthorization = _eventChannelAuthorization
.receiveBroadcastStream()
.map((dynamic event) => AuthorizationEvent(event));
}
_registerSubscription(_eventsAuthorization!.listen(callback), callback);
return Subscription._(() async {
removeListener(callback);
});
}
/// __(Android only)__ Registers a button-click listener on a [Custom Notification Layout](https://github.com/transistorsoft/flutter_background_geolocation/wiki/Android-Custom-Notification-Layout)
///
/// 
///
/// ℹ️ See also:
/// - [Android Custom Notification Layout](https://github.com/transistorsoft/flutter_background_geolocation/wiki/Android-Custom-Notification-Layout)