Closed
Description
private Subscriber<Location> onLocationUpdated = new Subscriber<Location>() {
@Override
public void onNext(Location location) {
// never called when was resumed after pause
}
...
}
Subscription subscription = Subscriptions.empty();
void onResume() {
subscription = locationService.observe().subscribe(onLocationUpdated);
}
void onPause() {
subscription.unsubscribe();
}
I have a class field with subscriber implementation. When my UI resumed I subscribe using that subscriber on location updates. When UI is paused I unsubscribe.
Subscriber is field is not destroyed when UI is paused and should be reused for subscribe on UI resume. Unfortunately onNext will be never called.
Guess this related to this fix #1409.
Metadata
Metadata
Assignees
Labels
No labels