Do not deliver result if view is destroyed
This commit is contained in:
parent
b617397397
commit
068a4255c1
|
@ -62,6 +62,15 @@ public class ChaptersFragment extends ListFragment {
|
|||
EventBus.getDefault().register(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDestroyView() {
|
||||
super.onDestroyView();
|
||||
|
||||
if (disposable != null) {
|
||||
disposable.dispose();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onStop() {
|
||||
super.onStop();
|
||||
|
|
|
@ -115,4 +115,13 @@ public class CoverFragment extends Fragment {
|
|||
controller.release();
|
||||
controller = null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDestroyView() {
|
||||
super.onDestroyView();
|
||||
|
||||
if (disposable != null) {
|
||||
disposable.dispose();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue