Leaflet/spec/suites/control
Daniel Ritz 0af11b064e Fix attribution text not removed when Layer is removed from map
Symptom: Switching between layers with different attributions does
not remove the attribution from the previously selected layer.

Control.Attribution keeps track of its attributions with a counter for
each text. The problem described in #4285 is that each time the layer
is added to the map, the counter is increased by two. It's because
Layer calls Control.Attribution.addAttribution() twice, once from
addLayer() and the second time via the whenReady() callback _layerAdd().
This was not caught by the tests since the callback was never fired
(missing map.setView() call).

Fixes #4285
2016-03-01 13:46:40 +01:00
..
Control.AttributionSpec.js Fix attribution text not removed when Layer is removed from map 2016-03-01 13:46:40 +01:00
Control.LayersSpec.js Better cleanup of L.Control.Layers, fixes #4213 (plus unit tests) 2016-02-09 15:43:03 +01:00
Control.ScaleSpec.js Fix semicolons, breaking, whitespace, duplicate var statements. 2013-02-19 11:18:15 -05:00
ControlSpec.js No-op Control#remove if not on a map (fixes #2877) 2014-11-13 11:25:49 -08:00