Merge pull request #763 from Meibes/feature/MapScaleBarLayer/onDetach
MapScaleBarLayer: add onDetach-method to free resources automatically
This commit is contained in:
@@ -62,4 +62,10 @@ public class MapScaleBarLayer extends Layer implements Map.UpdateListener {
|
||||
|
||||
mapScaleBar.redrawNeeded = false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDetach() {
|
||||
super.onDetach();
|
||||
mapScaleBar.destroy();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user