[v6.4.0] refactor: 优化fragment移除时反注册时机,时机提前;

This commit is contained in:
aibingbing
2024-04-29 17:31:22 +08:00
parent 35c19eb812
commit 28d7398b19
10 changed files with 35 additions and 3 deletions

View File

@@ -131,6 +131,14 @@ public class BusPassengerRouteFragment extends
}
}
@Override
public void onDestroyView() {
if (mPresenter != null) {
mPresenter.onDestroy(this);
}
super.onDestroyView();
}
@Override
public void onDestroy() {
super.onDestroy();

View File

@@ -126,6 +126,9 @@ class PM2DrivingInfoFragment :
override fun onDestroyView() {
overMapView?.onDestroy()
if (mPresenter != null) {
mPresenter?.onDestroy(this)
}
super.onDestroyView()
}