Closed kotran88 closed 1 year ago
on location_service_repository.dart
Future<void> callback(LocationDto locationDto) async { try { print('$_count location in dart: ${locationDto.toString()}'); final SendPort? send = IsolateNameServer.lookupPortByName(isolateName); send?.send(locationDto); _count++; } catch (e) { // code for handling exception print("error : $e"); } }
and receiving controller...
port.listen( (dynamic data) async { print("enter inside listen....."); print(data); await updateUI(data); }, );
it works very well when app is foreground or background from callback, I send then on controller, it received well.
but the problem comes when app is killed. it dosen't reach to port.listen inside.
how can I pass location data from callback to controller even when app is killed.
@kotran88 Did you get solution for above problem ?
on location_service_repository.dart
and receiving controller...
it works very well when app is foreground or background from callback, I send then on controller, it received well.
but the problem comes when app is killed. it dosen't reach to port.listen inside.
how can I pass location data from callback to controller even when app is killed.