Skip to content

Commit e6a12ba

Browse files
committed
remove checks for button 1
1 parent f635746 commit e6a12ba

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

js/webui/src/elements.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -92,13 +92,13 @@ export class RepeatingButton extends React.PureComponent
9292

9393
handleClick(e)
9494
{
95-
if (e.button === 0 || e.button === 1)
96-
{
97-
e.preventDefault();
95+
if (e.button !== 0)
96+
return;
9897

99-
if (e.button === 0 && !this.hasInitialClick)
100-
this.props.onClick();
101-
}
98+
e.preventDefault();
99+
100+
if (!this.hasInitialClick)
101+
this.props.onClick();
102102
}
103103

104104
componentDidUpdate(prevProps, prevState, snapshot)

0 commit comments

Comments
 (0)