Skip to content

Commit

Permalink
Fix concerning #103
Browse files Browse the repository at this point in the history
  • Loading branch information
Rainer Simon committed Nov 11, 2021
1 parent f8b8040 commit 3edadf5
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/OSDAnnotationLayer.js
Original file line number Diff line number Diff line change
Expand Up @@ -343,8 +343,11 @@ export class AnnotationLayer extends EventEmitter {
this.selectedShape.mouseTracker.destroy();
this.selectedShape.destroy();

if (!annotation.isSelection)
this.addAnnotation(annotation);
if (!annotation.isSelection) {
const shape = this.addAnnotation(annotation);
if (hasClass(shape, 'a9s-non-scaling'))
shape.setAttribute('transform', `scale(${1 / this.currentScale()})`);
}
}

this.selectedShape = null;
Expand Down

0 comments on commit 3edadf5

Please sign in to comment.