We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents e40fd17 + 6b545d6 commit 48cc67fCopy full SHA for 48cc67f
src/display/editor/annotation_editor_layer.js
@@ -553,6 +553,15 @@ class AnnotationEditorLayer {
553
* @param {PointerEvent} event
554
*/
555
pointerdown(event) {
556
+ if (this.#hadPointerDown) {
557
+ // It's possible to have a second pointerdown event before a pointerup one
558
+ // when the user puts a finger on a touchscreen and then add a second one
559
+ // to start a pinch-to-zoom gesture.
560
+ // That said, in case it's possible to have two pointerdown events with
561
+ // a mouse, we don't want to create a new editor in such a case either.
562
+ this.#hadPointerDown = false;
563
+ return;
564
+ }
565
const { isMac } = FeatureTest.platform;
566
if (event.button !== 0 || (event.ctrlKey && isMac)) {
567
// Do nothing on right click.
0 commit comments