mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-23 08:38:06 +02:00
[Editor] Disable context menu on alt-text button and in the associated dialog
but keep it for the text area. Disable pointerdown on the alt-text button to disable dragging the editor when the button is clicked (especially when slightly moving the mouse between the down and the up).
This commit is contained in:
parent
85568bd6cc
commit
88f3ed7745
2 changed files with 7 additions and 0 deletions
|
@ -834,6 +834,8 @@ class AnnotationEditor {
|
|||
altText.textContent = msg;
|
||||
altText.setAttribute("aria-label", msg);
|
||||
altText.tabIndex = "0";
|
||||
altText.addEventListener("contextmenu", AnnotationEditor.#noContextMenu);
|
||||
altText.addEventListener("pointerdown", event => event.stopPropagation());
|
||||
altText.addEventListener(
|
||||
"click",
|
||||
event => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue