update build and changelog

This commit is contained in:
Vladimir Agafonkin 2012-08-01 14:14:23 +03:00
parent 690c969bc0
commit 2020827a9e
3 changed files with 37 additions and 9 deletions

View File

@ -7,6 +7,11 @@ Leaflet Changelog
An in-progress version being developed on the master branch. An in-progress version being developed on the master branch.
## 0.4.2 (August 1, 2012)
* Fixed a bug where layers control radio buttons would not work correctly in IE7 (by [@danzel](https://github.com/danzel)). [#862](https://github.com/CloudMade/Leaflet/pull/862)
* Fixed a bug where `FeatureGroup` `removeLayer` would unbind popups of removed layers even if the popups were not put by the group (affected [Leaflet.markercluster](https://github.com/danzel/Leaflet.markercluster) plugin) (by [@danzel](https://github.com/danzel)). [#861](https://github.com/CloudMade/Leaflet/pull/861)
## 0.4.1 (July 31, 2012) ## 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 that caused marker shadows appear as opaque black in IE6-8. [#850](https://github.com/CloudMade/Leaflet/issues/850)

37
dist/leaflet-src.js vendored
View File

@ -3513,7 +3513,11 @@ L.FeatureGroup = L.LayerGroup.extend({
L.LayerGroup.prototype.removeLayer.call(this, layer); L.LayerGroup.prototype.removeLayer.call(this, layer);
if (this._popupContent) {
return this.invoke('unbindPopup'); return this.invoke('unbindPopup');
} else {
return this;
}
}, },
bindPopup: function (content) { bindPopup: function (content) {
@ -6925,16 +6929,35 @@ L.Control.Layers = L.Control.extend({
this._separator.style.display = (overlaysPresent && baseLayersPresent ? '' : 'none'); this._separator.style.display = (overlaysPresent && baseLayersPresent ? '' : 'none');
}, },
_addItem: function (obj, onclick) { // IE7 bugs out if you create a radio dynamically, so you have to do it this hacky way (see http://bit.ly/PqYLBe)
var label = document.createElement('label'); _createRadioElement: function (name, checked) {
var input = document.createElement('input'); var radioHtml = '<input type="radio" name="' + name + '"';
if (!obj.overlay) { if (checked) {
input.name = 'leaflet-base-layers'; radioHtml += ' checked="checked"';
} }
input.type = obj.overlay ? 'checkbox' : 'radio'; radioHtml += '/>';
var radioFragment = document.createElement('div');
radioFragment.innerHTML = radioHtml;
return radioFragment.firstChild;
},
_addItem: function (obj) {
var label = document.createElement('label'),
input,
checked = this._map.hasLayer(obj.layer);
if (obj.overlay) {
input = document.createElement('input');
input.type = 'checkbox';
input.defaultChecked = checked;
} else {
input = this._createRadioElement('leaflet-base-layers', checked);
}
input.layerId = L.Util.stamp(obj.layer); input.layerId = L.Util.stamp(obj.layer);
input.defaultChecked = this._map.hasLayer(obj.layer);
L.DomEvent.on(input, 'click', this._onInputClick, this); L.DomEvent.on(input, 'click', this._onInputClick, this);

2
dist/leaflet.js vendored

File diff suppressed because one or more lines are too long