Skip to content

Commit

Permalink
Merge branch 'master' into dev_OlSketchHandler_cleanup_finishOnFirstP…
Browse files Browse the repository at this point in the history
…oint-property
  • Loading branch information
thiloSchlemmer committed Jan 7, 2025
2 parents 009092f + 5555eab commit d7b9b6a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
7 changes: 1 addition & 6 deletions src/modules/olMap/components/OlMap.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import olCss from 'ol/ol.css';
import css from './olMap.css';
import { Map as MapOl, View } from 'ol';
import { defaults as defaultControls, ScaleLine } from 'ol/control';
import { defaults as defaultInteractions, PinchRotate, DragPan } from 'ol/interaction';
import { defaults as defaultInteractions, PinchRotate } from 'ol/interaction';
import { removeLayer } from '../../../store/layers/layers.action';
import { changeLiveCenter, changeLiveRotation, changeLiveZoom, changeZoomCenterAndRotation } from '../../../store/position/position.action';
import { $injector } from '../../../injection';
Expand Down Expand Up @@ -171,11 +171,6 @@ export class OlMap extends MvuElement {
}).extend([
new PinchRotate({
threshold: this._mapService.getMinimalRotation()
}),
new DragPan({
condition: (mapBrowserEvent) => {
return mapBrowserEvent.originalEvent.isPrimary && mapBrowserEvent.originalEvent.button < 2;
}
})
])
});
Expand Down
2 changes: 1 addition & 1 deletion test/modules/olMap/components/OlMap.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ describe('OlMap', () => {
//all default controls are removed, ScaleLine control added
expect(element._map.getControls().getLength()).toBe(1);
//all interactions are present
expect(element._map.getInteractions().getLength()).toBe(10);
expect(element._map.getInteractions().getLength()).toBe(9);
expect(element._map.moveTolerance_).toBe(1);
expect(mapServiceSpy).toHaveBeenCalled();
});
Expand Down

0 comments on commit d7b9b6a

Please sign in to comment.