Permalink
Browse files

update build and changelog

  • Loading branch information...
1 parent 7622bfe commit a393cdec20c8349ce2869cc091479bc7042aa248 @mourner mourner committed Jul 31, 2012
Showing with 15 additions and 7 deletions.
  1. +4 −0 CHANGELOG.md
  2. +9 −5 dist/leaflet-src.js
  3. +1 −1 dist/leaflet.js
  4. +1 −1 src/Leaflet.js
View
@@ -7,8 +7,12 @@ Leaflet Changelog
An in-progress version being developed on the master branch.
+## 0.4.1 (July 31, 2012)
+
* Fixed a bug that caused marker shadows appear as opaque black in IE6-8. [#850](https://github.com/CloudMade/Leaflet/issues/850)
* Fixed a bug with incorrect calculation of scale by the scale control. [#852](https://github.com/CloudMade/Leaflet/issues/852)
+ * Fixed broken L.tileLayer.wms class factory (by [@mattcurrie](https://github.com/mattcurrie)). [#856](https://github.com/CloudMade/Leaflet/issues/856)
+ * Improved retina detection for `TileLayer` `detectRetina` option (by [@sxua](https://github.com/sxua)). [#854](https://github.com/CloudMade/Leaflet/issues/854)
## 0.4 (July 30, 2012)
View
@@ -21,7 +21,7 @@ if (typeof exports !== undefined + '') {
window.L = L;
}
-L.version = '0.4';
+L.version = '0.4.1';
/*
@@ -382,6 +382,8 @@ L.Mixin.Events.fire = L.Mixin.Events.fireEvent;
return supported;
}());
+ var retina = (('devicePixelRatio' in window && window.devicePixelRatio > 1) || ('matchMedia' in window && window.matchMedia("(min-resolution:144dpi)").matches));
+
L.Browser = {
ua: ua,
ie: ie,
@@ -405,7 +407,9 @@ L.Mixin.Events.fire = L.Mixin.Events.fireEvent;
mobileWebkit3d: mobile && webkit3d,
mobileOpera: mobile && opera,
- touch: touch
+ touch: touch,
+
+ retina: retina
};
}());
@@ -1890,7 +1894,7 @@ L.TileLayer = L.Class.extend({
options = L.Util.setOptions(this, options);
// detecting retina displays, adjusting tileSize and zoom levels
- if (options.detectRetina && window.devicePixelRatio > 1 && options.maxZoom > 0) {
+ if (options.detectRetina && L.Browser.retina && options.maxZoom > 0) {
options.tileSize = Math.floor(options.tileSize / 2);
options.zoomOffset++;
@@ -2398,7 +2402,7 @@ L.TileLayer.WMS = L.TileLayer.extend({
var wmsParams = L.Util.extend({}, this.defaultWmsParams);
- if (options.detectRetina && window.devicePixelRatio > 1) {
+ if (options.detectRetina && L.Browser.retina) {
wmsParams.width = wmsParams.height = this.options.tileSize * 2;
} else {
wmsParams.width = wmsParams.height = this.options.tileSize;
@@ -2456,7 +2460,7 @@ L.TileLayer.WMS = L.TileLayer.extend({
});
L.tileLayer.wms = function (url, options) {
- return new L.TileLayer(url, options);
+ return new L.TileLayer.WMS(url, options);
};
View

Large diffs are not rendered by default.

Oops, something went wrong.
View
@@ -14,4 +14,4 @@ if (typeof exports !== undefined + '') {
window.L = L;
}
-L.version = '0.4';
+L.version = '0.4.1';

0 comments on commit a393cde

Please sign in to comment.