Skip to content

Commit

Permalink
[BUG] selection
Browse files Browse the repository at this point in the history
  • Loading branch information
Viglino committed Jul 30, 2021
1 parent 779e0af commit d1b4cf2
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion dist/ol-ext.js
Original file line number Diff line number Diff line change
Expand Up @@ -3918,7 +3918,7 @@ ol.control.LayerSwitcher.prototype.drawList = function(ul, collection) {
e.preventDefault();
var l = self._getLayerForLI(this.parentNode.parentNode);
self.switchLayerVisibility(l, collection);
if (l.getVisible()) {
if (self.get('selection') && l.getVisible()) {
self.selectLayer(l);
}
};
Expand Down
2 changes: 1 addition & 1 deletion dist/ol-ext.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/control/LayerSwitcher.js
Original file line number Diff line number Diff line change
Expand Up @@ -660,7 +660,7 @@ ol_control_LayerSwitcher.prototype.drawList = function(ul, collection) {
e.preventDefault();
var l = self._getLayerForLI(this.parentNode.parentNode);
self.switchLayerVisibility(l, collection);
if (l.getVisible()) {
if (self.get('selection') && l.getVisible()) {
self.selectLayer(l);
}
};
Expand Down

0 comments on commit d1b4cf2

Please sign in to comment.