内存泄漏问题优化

This commit is contained in:
wangcongtao
2021-01-11 11:31:40 +08:00
parent 9273942a42
commit 49ab4e52de
5 changed files with 16 additions and 2 deletions

View File

@@ -76,7 +76,7 @@ public class AMapNaviViewWrapper implements IMogoMapView,
private static final String TAG = "AMapNaviViewWrapper";
private final AMapNaviView mMapView;
private AMapNaviView mMapView;
private IMogoMap mIMap;
private AMapMarkerClickHandler mMarkerClickHandler;
@@ -239,8 +239,10 @@ public class AMapNaviViewWrapper implements IMogoMapView,
public void onDestroy() {
if ( mMapView != null ) {
mMapView.onDestroy();
mMapView = null;
AMapUIController.release();
AMapWrapper.release();
AMapMessageManager.getInstance().unregisterAMapMessageListener( this );
Logger.d( TAG, "map onDestroy" );
}
}