Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

eframe web: Don't throw away frames on click/copy/cut #3623

Merged
merged 3 commits into from Nov 24, 2023

Conversation

emilk
Copy link
Owner

@emilk emilk commented Nov 24, 2023

To work around a Safari limitation, we run the app logic in the event handler of copy, cut, and mouse up and down.

Previously the output of that frame was discarded, but in this PR it is now saved to be used in the next requestAnimationFrame.

The result is noticeable more distinct clicks on buttons (one more frame of highlight)

Bonus: also fix auto-save of a sleeping web app

To work around a Safari limitation, we run the app logic in the event
handler of copy, cut, and mouse up and down.

Previously the output of that frame was discarded, but in this PR
it is now saved to be used in the next requestAnimationFrame.

The result is noticeable more distinct clicks on buttons
(one more frame of highlight)
@emilk emilk added bug Something is broken web Related to running Egui on the web eframe Relates to epi and eframe labels Nov 24, 2023
@emilk emilk merged commit 23732be into master Nov 24, 2023
35 checks passed
@emilk emilk deleted the emilk/dont-throw-away-frames branch November 24, 2023 09:08
emilk added a commit that referenced this pull request Nov 27, 2023
Closes #3633

Bug introduced in #3623 (after 0.24.0 was cut)
@emilk emilk mentioned this pull request Nov 27, 2023
emilk added a commit that referenced this pull request Nov 27, 2023
Closes #3633

Bug introduced in #3623 (after 0.24.0 was cut)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is broken eframe Relates to epi and eframe web Related to running Egui on the web
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant