Skip to content

Commit 2bb1a98

Browse files
committed
Interaction: Use button and buttons to determine device button state
1 parent e4314bc commit 2bb1a98

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

ui/jquery.ui.interaction.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,8 @@ pointerHook = interaction.hooks.pointer = {
9898
return;
9999
}
100100

101-
// only react to the primary button
102-
if ( event.pointerId !== 1 || event.which === 1 ) {
101+
// only react to the primary button or touch
102+
if ( event.button === 0 && event.buttons === 1 ) {
103103
var started = start( event, event.target, {
104104
x: event.pageX,
105105
y: event.pageY

0 commit comments

Comments
 (0)