Ignore:
Timestamp:
2015-08-08T12:35:53+02:00 (9 years ago)
Author:
wiktorn
Message:

Add support for custom headers sending in OsmTileLoader

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer/OsmTileLoader.java

    r31434 r31467  
    104104
    105105    public OsmTileLoader(TileLoaderListener listener) {
    106         headers.put("Accept", "text/html, image/png, image/jpeg, image/gif, */*");
     106        this(listener, null);
     107    }
     108
     109    public OsmTileLoader(TileLoaderListener listener, Map<String, String> headers) {
     110        this.headers.put("Accept", "text/html, image/png, image/jpeg, image/gif, */*");
     111        if (headers != null) {
     112            this.headers.putAll(headers);
     113        }
    107114        this.listener = listener;
    108115    }
     116
    109117
    110118    @Override
Note: See TracChangeset for help on using the changeset viewer.