examples/keyboard_events Holding A and left clicking Clear button generates both Pressed and Held text
- Dominant language
- Rust
- Stars
- 30.6k
- Forks
- 2.1k
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 72
Description
**Describe the bug**
**To Reproduce**
Steps to reproduce the behavior:
1. `cd tmp && git clone https://github.com/emilk/egui.git`
2. `cd egui`
3. `cargo run -p keyboard_events`
4. now hold `A` key and then left click on the `Clear` button once.
5. keep holding `A` key and left click on `Clear` as many times as you want.
**Expected behavior**
only `Held` should be seen after doing step 4 or 5.
**Screenshots**

**Desktop (please complete the following information):**
- OS: Gentoo Linux x64
- Browser n/a
- Version 2.13
**Smartphone (please complete the following information):**
- Device: n/a
- OS:
- Browser
- Version
**Additional context**
X.Org X Server 1.21.1.7
Contributor guide
Research direction
Run `cargo run -p keyboard_events` and reproduce the behavior by holding A while clicking Clear. Trace the keyboard and button event handling used by the `examples/keyboard_events` package, verify the issue against the latest master, and consider it done when repeated clicks while A is held show only `Held`.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100