mirror of
https://github.com/FoggedLens/iD.git
synced 2026-05-24 09:04:02 +02:00
Exclude Locator Overlay from imagery_used
This commit is contained in:
@@ -52,7 +52,10 @@ iD.Background = function(context) {
|
||||
}
|
||||
|
||||
overlayLayers.forEach(function (d) {
|
||||
imageryUsed.push(d.source().sourcetag || d.source().name);
|
||||
var source = d.source();
|
||||
if (!source.isLocatorOverlay()) {
|
||||
imageryUsed.push(source.sourcetag || source.name);
|
||||
}
|
||||
});
|
||||
|
||||
if (background.showsGpxLayer()) {
|
||||
|
||||
@@ -51,7 +51,11 @@ iD.BackgroundSource = function(data) {
|
||||
|
||||
source.validZoom = function(z) {
|
||||
return source.scaleExtent[0] <= z &&
|
||||
(source.name !== 'Locator Overlay' || source.scaleExtent[1] > z);
|
||||
(!source.isLocatorOverlay() || source.scaleExtent[1] > z);
|
||||
};
|
||||
|
||||
source.isLocatorOverlay = function() {
|
||||
return source.name === 'Locator Overlay';
|
||||
};
|
||||
|
||||
source.copyrightNotices = function() {};
|
||||
|
||||
Reference in New Issue
Block a user