Mouse Button Test
Click, scroll and press the side buttons inside the pad. Each action is counted separately, so a button that registers twice or not at all shows up in the numbers.
- Move the pointer into the dashed area.
- Press each button a few times. Its counter should rise by one per press.
- Scroll the wheel up and down, and tilt it sideways if your mouse has a tilt wheel.
- Check the line under the area: it shows which buttons are held while you move the mouse.
What each button should report
| Status | You see | What it means |
|---|---|---|
| Healthy | Left, Middle and Right each count one per click | The three main switches register once per press. |
| Fault | One click raises a counter by two | A worn switch can send a second press (a double-click fault). |
| Fault | A button never raises its counter | The button is dead, remapped in the vendor software or taken by the operating system for another action. |
| Check | Back and Forward do nothing | Browsers report them as buttons 3 and 4, but a mouse driver may map them to its own actions before the page sees them. |
| Check | Wheel counts vary for one scroll | The page counts wheel events, not notches. High-resolution or smooth-scrolling wheels send many small events per notch. |
Two ways a browser describes a button
A mouse event exposes the button in two shapes. event.button is an index for the button that changed: 0 left, 1 middle, 2 right, 3 back, 4 forward. event.buttons is a bit mask of everything held at that moment: 1 left, 2 right, 4 middle, 8 back, 16 forward. The two orders differ, since the mask puts right before middle, which is why the page decodes the mask through its own table.
The counters use the index on mouse down. The "held now" line decodes the mask, so pressing left and right together shows both names at once, which is the quickest way to find a pair of buttons that cannot be held together.
The wheel direction comes from the larger of the two deltas, vertical first: a negative vertical delta is up, a positive one is down, and when the horizontal delta is larger the sign gives left or right. A tilt wheel therefore counts left and right separately.
The pad cancels the context menu and the auxiliary-click default, otherwise a right click would open the browser menu over the pad.
This confirms that events arrive. It does not time the switch, detect button bounce at sub-millisecond level, or report the sensor quality. For a double-registering button use the double-click test.
- Mouse Double-Click TestSeparate a real double-click from a switch that fires twice.
- Mouse Polling Rate TestCheck how often the mouse reports its position.