Ignore:
Timestamp:
2017-08-24T00:15:51+02:00 (7 years ago)
Author:
Don-vip
Message:

see #15182 - deprecate Main.map and Main.isDisplayingMapView(). Replacements: gui.MainApplication.getMap() / gui.MainApplication.isDisplayingMapView()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/actions/SessionLoadAction.java

    r12620 r12630  
    2121import org.openstreetmap.josm.Main;
    2222import org.openstreetmap.josm.gui.HelpAwareOptionPane;
     23import org.openstreetmap.josm.gui.MainApplication;
    2324import org.openstreetmap.josm.gui.PleaseWaitRunnable;
    2425import org.openstreetmap.josm.gui.layer.Layer;
     
    133134        private void addLayers() {
    134135            if (layers != null && !layers.isEmpty()) {
    135                 boolean noMap = Main.map == null;
     136                boolean noMap = MainApplication.getMap() == null;
    136137                for (Layer l : layers) {
    137138                    if (canceled)
     
    143144                }
    144145                if (noMap && viewport != null) {
    145                     Main.map.mapView.scheduleZoomTo(viewport.getEastNorthViewport(Main.getProjection()));
     146                    MainApplication.getMap().mapView.scheduleZoomTo(viewport.getEastNorthViewport(Main.getProjection()));
    146147                }
    147148            }
Note: See TracChangeset for help on using the changeset viewer.