Skip to content

Commit

Permalink
Fixed another touch/cross-browser issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Rainer Simon committed Nov 9, 2021
1 parent 233f815 commit 141e428
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/OSDAnnotationLayer.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ export class AnnotationLayer extends EventEmitter {
const getSVGPoint = evt => {
const pt = this.svg.createSVGPoint();

if (evt instanceof TouchEvent) {
if (window.TouchEvent && (evt instanceof TouchEvent)) {
const bbox = this.svg.getBoundingClientRect();

const e = evt.touches[0];
Expand Down

0 comments on commit 141e428

Please sign in to comment.