Skip to content

Commit

Permalink
Merge pull request #5130 from nboisteault/fix-PR-5069
Browse files Browse the repository at this point in the history
Fix PR 5069
  • Loading branch information
nboisteault authored Dec 16, 2024
2 parents f826c1d + b61a55b commit bc87d1d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion assets/src/components/Print.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ export default class Print extends HTMLElement {
mainLizmap.map.getView().on('change:resolution', this._onChangeResolution);

render(this._template(), this);
} else if (e.navElements.includes('print nav-minidock active')) { // Remove print overlay when clicking on another minidock
} else {
mainLizmap.map.removeToolLayer(this._maskLayer);
mainLizmap.map.getView().un('change:resolution', this._onChangeResolution);
}
Expand Down
4 changes: 1 addition & 3 deletions assets/src/legacy/map.js
Original file line number Diff line number Diff line change
Expand Up @@ -3407,9 +3407,7 @@ window.lizMap = function() {

const dockContentSelector = dockType == 'minidock' ? '#mini-dock-content > div' : '#' + dockType + '-content > div';

let navElements = [];
document.querySelectorAll('#mapmenu .nav-' + dockType).forEach(element => {
navElements.push(element.className);
element.classList.remove('active');
});
document.querySelectorAll(dockContentSelector).forEach(element => element.classList.add('hide'));
Expand All @@ -3421,7 +3419,7 @@ window.lizMap = function() {
const dockEvent = dockType == 'right-dock' ? 'rightdock' : dockType;

const lizmapEvent = wasActive ? dockEvent + 'closed' : dockEvent + 'opened';
lizMap.events.triggerEvent(lizmapEvent, { 'id': dockId, 'navElements': navElements});
lizMap.events.triggerEvent(lizmapEvent, { 'id': dockId });

return false;
});
Expand Down

0 comments on commit bc87d1d

Please sign in to comment.