Skip to content

Commit

Permalink
Merge pull request #120 from semone/leaflet-proj-refactor
Browse files Browse the repository at this point in the history
Leaflet proj refactor
  • Loading branch information
Peter Thorin authored Sep 5, 2016
2 parents ec8faa3 + 7345856 commit 6feb358
Show file tree
Hide file tree
Showing 26 changed files with 8,413 additions and 4,437 deletions.
4 changes: 2 additions & 2 deletions examples/geojson-crs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
<head>
<meta charset="utf-8" />
<link rel="stylesheet" href="style.css" />
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet/v1.0.0-beta.2/leaflet.css" />
<link rel="stylesheet" href="../../lib/leaflet/leaflet.css" />
</head>
<body>
<div id="map"></div>
<script src="http://cdn.leafletjs.com/leaflet/v1.0.0-beta.2/leaflet-src.js"></script>
<script src="../../lib/leaflet/leaflet.js"></script>
<script src="../../lib/proj4-compressed.js"></script>
<script src="../../src/proj4leaflet.js"></script>
<script src="script.js"></script>
Expand Down
14 changes: 5 additions & 9 deletions examples/geojson-crs/script.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,14 @@
var map = L.map('map').setView([44.97,-93.24], 11);

// MapQuest OSM Tiles

// Attribution (https://gist.github.com/mourner/1804938)
var osmAttr = 'Map data &copy; <a href="http://openstreetmap.org">OpenStreetMap</a> contributors, <a href="http://creativecommons.org/licenses/by-sa/2.0/">CC-BY-SA</a>',
mqTilesAttr = 'Tiles &copy; <a href="http://www.mapquest.com/"" target="_blank">MapQuest</a> <img src="http://developer.mapquest.com/content/osm/mq_logo.png" />';
// OSM Tiles

L.tileLayer(
'http://otile{s}.mqcdn.com/tiles/1.0.0/map/{z}/{x}/{y}.png',
'http://tile.openstreetmap.org/{z}/{x}/{y}.png',
{
subdomains: '1234',
attribution: osmAttr + ', ' + mqTilesAttr
attribution: 'Data by <a href="http://openstreetmap.org">OpenStreetMap contributors</a>'
}
).addTo(map);
)
.addTo(map);

// GeoJSON layer (UTM15)
proj4.defs('EPSG:26915', '+proj=utm +zone=15 +ellps=GRS80 +datum=NAD83 +units=m +no_defs');
Expand Down
4 changes: 2 additions & 2 deletions examples/local-projections/europe/index_austria.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
<head>
<meta charset="utf-8" />
<link rel="stylesheet" href="../style.css" />
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet/v1.0.0-beta.2/leaflet.css" />
<link rel="stylesheet" href="../../../lib/leaflet/leaflet.css" />
</head>
<body>
<div id="map"></div>
<script src="http://cdn.leafletjs.com/leaflet/v1.0.0-beta.2/leaflet-src.js"></script>
<script src="../../../lib/leaflet/leaflet.js"></script>
<script src="../../../lib/proj4-compressed.js"></script>
<script src="../../../src/proj4leaflet.js"></script>
<script src="script_austria.js"></script>
Expand Down
4 changes: 2 additions & 2 deletions examples/local-projections/nz/index_auckland.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
<head>
<meta charset="utf-8" />
<link rel="stylesheet" href="../style.css" />
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet/v1.0.0-beta.2/leaflet.css" />
<link rel="stylesheet" href="../../../lib/leaflet/leaflet.css" />
</head>
<body>
<div id="map"></div>
<script src="http://cdn.leafletjs.com/leaflet/v1.0.0-beta.2/leaflet-src.js"></script>
<script src="../../../lib/leaflet/leaflet.js"></script>
<script src="../../../lib/proj4-compressed.js"></script>
<script src="../../../src/proj4leaflet.js"></script>
<script src="script_auckland.js"></script>
Expand Down
6 changes: 3 additions & 3 deletions examples/osm-tiled/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
<head>
<meta charset="utf-8" />
<link rel="stylesheet" href="style.css" />
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet/v1.0.0-beta.2/leaflet.css" />
</head>
<link rel="stylesheet" href="../../lib/leaflet/leaflet.css" />
</head>
<body>
<div id="map"></div>
<script src="http://cdn.leafletjs.com/leaflet/v1.0.0-beta.2/leaflet-src.js"></script>
<script src="../../lib/leaflet/leaflet.js"></script>
<script src="../../lib/proj4-compressed.js"></script>
<script src="../../src/proj4leaflet.js"></script>
<script src="script.js"></script>
Expand Down
4 changes: 2 additions & 2 deletions examples/tms-tiled/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
<head>
<meta charset="utf-8" />
<link rel="stylesheet" href="style.css" />
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet/v1.0.0-beta.2/leaflet.css" />
<link rel="stylesheet" href="../../lib/leaflet/leaflet.css" />
</head>
<body>
<div id="map"></div>
<script src="http://cdn.leafletjs.com/leaflet/v1.0.0-beta.2/leaflet-src.js"></script>
<script src="../../lib/leaflet/leaflet.js"></script>
<script src="../../lib/proj4-compressed.js"></script>
<script src="../../src/proj4leaflet.js"></script>
<script src="script.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion examples/wms/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
</head>
<body>
<div id="map"></div>
<script src="../../lib/leaflet/leaflet-src.js"></script>
<script src="../../lib/leaflet/leaflet.js"></script>
<script src="../../lib/proj4-compressed.js"></script>
<script src="../../src/proj4leaflet.js"></script>
<script src="script.js"></script>
Expand Down
6 changes: 3 additions & 3 deletions examples/wms/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ var crs = new L.Proj.CRS('EPSG:3006',
crs: crs,
});

L.tileLayer.wms('http://geodatatest.havochvatten.se/geoservices/ows', {
L.tileLayer.wms('http://geodata.havochvatten.se/geoservices/hav-bakgrundskartor/ows', {
layers: 'hav-bakgrundskartor:hav-grundkarta',
format: 'image/png',
maxZoom: 14,
minZoom: 0,
attribution: '&copy; <a href="https://www.havochvatten.se/kunskap-om-vara-vatten/kartor-och-geografisk-information/karttjanster.html">Havs- och vattenmyndigheten (Swedish Agency for Marine and Water Management)</a>'
attribution: '&copy; OpenStreetMap contributors <a href="https://www.havochvatten.se/kunskap-om-vara-vatten/kartor-och-geografisk-information/karttjanster.html">Havs- och vattenmyndigheten (Swedish Agency for Marine and Water Management)</a>'
}).addTo(map);

map.setView([55.8, 14.3], 6);
map.setView([55.8, 14.3], 3);
Binary file removed lib/images/layers-2x.png
Binary file not shown.
Binary file removed lib/images/layers.png
Binary file not shown.
Binary file removed lib/images/marker-icon-2x.png
Binary file not shown.
Binary file removed lib/images/marker-icon.png
Binary file not shown.
Binary file removed lib/images/marker-shadow.png
Binary file not shown.
Binary file removed lib/images/zoom-in.png
Binary file not shown.
Binary file removed lib/images/zoom-out.png
Binary file not shown.
Binary file modified lib/leaflet/images/layers-2x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified lib/leaflet/images/layers.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified lib/leaflet/images/marker-icon-2x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified lib/leaflet/images/marker-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified lib/leaflet/images/marker-shadow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 6feb358

Please sign in to comment.