Changeset 35803 in osm


Ignore:
Timestamp:
2021-08-11T20:26:21+02:00 (3 years ago)
Author:
Don-vip
Message:

fix #21210 - honor "zoom to downloaded data" setting

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/opendata/src/org/openstreetmap/josm/plugins/opendata/core/actions/DownloadDataTask.java

    r34805 r35803  
    3333    @Override
    3434    public Future<?> loadUrl(DownloadParams settings, String url, ProgressMonitor progressMonitor) {
    35         downloadTask = new InternalDownloadTasK(settings, new NetworkReader(url, handler, true), progressMonitor);
     35        downloadTask = new InternalDownloadTask(settings, new NetworkReader(url, handler, true), progressMonitor, zoomAfterDownload);
    3636        currentBounds = null;
    3737        if (handler == null || !handler.hasLicenseToBeAccepted() || askLicenseAgreement(handler.getLicense())) {
     
    7878    }
    7979
    80     protected class InternalDownloadTasK extends DownloadTask {
     80    protected class InternalDownloadTask extends DownloadTask {
    8181
    82         public InternalDownloadTasK(DownloadParams settings, NetworkReader reader, ProgressMonitor progressMonitor) {
    83             super(settings, reader, progressMonitor);
     82        public InternalDownloadTask(DownloadParams settings, NetworkReader reader, ProgressMonitor progressMonitor, boolean zoomAfterDownload) {
     83            super(settings, reader, progressMonitor, zoomAfterDownload);
    8484        }
    8585
     
    112112        try {
    113113            return new AskLicenseAgreementDialog(license).showDialog().getValue() == 1;
    114 
    115114        } catch (IOException e) {
    116115            JOptionPane.showMessageDialog(MainApplication.getMainFrame(), tr("License URL not available: {0}", license.toString()));
Note: See TracChangeset for help on using the changeset viewer.