use of com.revolsys.swing.map.overlay.AbstractOverlay in project com.revolsys.open by revolsys.
the class MapPanel method destroy.
public void destroy() {
setDropTarget(null);
Property.removeAllListeners(this);
setDropTarget(null);
this.layerOverlay.dispose();
for (final Component overlay : this.layeredPane.getComponents()) {
if (overlay instanceof AbstractOverlay) {
final AbstractOverlay abstractOverlay = (AbstractOverlay) overlay;
abstractOverlay.destroy();
}
}
removeAll();
this.layeredPane.removeAll();
this.statusBarPanel.removeAll();
this.leftStatusBar = null;
this.rightStatusBar = null;
if (this.baseMapLayers != null) {
this.baseMapLayers.delete();
}
this.baseMapLayers = null;
this.baseMapOverlay = null;
this.fileDropListener = null;
this.layerOverlay = null;
this.progressBar = null;
this.project.reset();
this.toolBar.clear();
this.toolTipOverlay = null;
this.undoManager.die();
Property.removeAllListeners(this.viewport.getPropertyChangeSupport());
this.zoomBookmarkButton = null;
this.zoomHistory.clear();
}
Aggregations