update build

This commit is contained in:
Vladimir Agafonkin 2012-07-24 14:07:49 +03:00
parent c47333c273
commit cfdbdffc49
2 changed files with 27 additions and 2 deletions

25
dist/leaflet-src.js vendored
View File

@ -1929,6 +1929,7 @@ L.TileLayer = L.Class.extend({
if (this._container) { if (this._container) {
this._map._panes.tilePane.appendChild(this._container); this._map._panes.tilePane.appendChild(this._container);
} }
return this;
}, },
bringToBack: function () { bringToBack: function () {
@ -1936,6 +1937,7 @@ L.TileLayer = L.Class.extend({
if (this._container) { if (this._container) {
pane.insertBefore(this._container, pane.firstChild); pane.insertBefore(this._container, pane.firstChild);
} }
return this;
}, },
getAttribution: function () { getAttribution: function () {
@ -1948,6 +1950,8 @@ L.TileLayer = L.Class.extend({
if (this._map) { if (this._map) {
this._updateOpacity(); this._updateOpacity();
} }
return this;
}, },
setUrl: function (url, noRedraw) { setUrl: function (url, noRedraw) {
@ -2469,6 +2473,7 @@ L.ImageOverlay = L.Class.extend({
setOpacity: function (opacity) { setOpacity: function (opacity) {
this.options.opacity = opacity; this.options.opacity = opacity;
this._updateOpacity(); this._updateOpacity();
return this;
}, },
_initImage: function () { _initImage: function () {
@ -3438,6 +3443,7 @@ L.Path = L.Class.extend({
options: { options: {
stroke: true, stroke: true,
color: '#0033ff', color: '#0033ff',
dashArray: null,
weight: 5, weight: 5,
opacity: 0.5, opacity: 0.5,
@ -3579,6 +3585,11 @@ L.Path = L.Path.extend({
this._path.setAttribute('stroke', this.options.color); this._path.setAttribute('stroke', this.options.color);
this._path.setAttribute('stroke-opacity', this.options.opacity); this._path.setAttribute('stroke-opacity', this.options.opacity);
this._path.setAttribute('stroke-width', this.options.weight); this._path.setAttribute('stroke-width', this.options.weight);
if (this.options.dashArray) {
this._path.setAttribute('stroke-dasharray', this.options.dashArray);
} else {
this._path.removeAttribute('stroke-dasharray');
}
} else { } else {
this._path.setAttribute('stroke', 'none'); this._path.setAttribute('stroke', 'none');
} }
@ -3835,6 +3846,11 @@ L.Path = L.Browser.svg || !L.Browser.vml ? L.Path : L.Path.extend({
stroke.weight = options.weight + 'px'; stroke.weight = options.weight + 'px';
stroke.color = options.color; stroke.color = options.color;
stroke.opacity = options.opacity; stroke.opacity = options.opacity;
if (options.dashArray) {
stroke.dashStyle = options.dashArray;
} else {
stroke.dashStyle = '';
}
} else if (stroke) { } else if (stroke) {
container.removeChild(stroke); container.removeChild(stroke);
this._stroke = null; this._stroke = null;
@ -6145,6 +6161,8 @@ L.Control = L.Class.extend({
if (map) { if (map) {
map.addControl(this); map.addControl(this);
} }
return this;
}, },
addTo: function (map) { addTo: function (map) {
@ -6184,6 +6202,7 @@ L.control = function (options) {
return new L.Control(options); return new L.Control(options);
}; };
L.Map.include({ L.Map.include({
addControl: function (control) { addControl: function (control) {
control.addTo(this); control.addTo(this);
@ -6295,6 +6314,7 @@ L.Control.Attribution = L.Control.extend({
setPrefix: function (prefix) { setPrefix: function (prefix) {
this.options.prefix = prefix; this.options.prefix = prefix;
this._update(); this._update();
return this;
}, },
addAttribution: function (text) { addAttribution: function (text) {
@ -6306,6 +6326,8 @@ L.Control.Attribution = L.Control.extend({
this._attributions[text]++; this._attributions[text]++;
this._update(); this._update();
return this;
}, },
removeAttribution: function (text) { removeAttribution: function (text) {
@ -6313,6 +6335,8 @@ L.Control.Attribution = L.Control.extend({
this._attributions[text]--; this._attributions[text]--;
this._update(); this._update();
return this;
}, },
_update: function () { _update: function () {
@ -6365,6 +6389,7 @@ L.control.attribution = function (options) {
return new L.Control.Attribution(options); return new L.Control.Attribution(options);
}; };
L.Control.Scale = L.Control.extend({ L.Control.Scale = L.Control.extend({
options: { options: {
position: 'bottomleft', position: 'bottomleft',

2
dist/leaflet.js vendored

File diff suppressed because one or more lines are too long