eventHandler: Drop hide events.#11072
Merged
Merged
Conversation
Aside from IAccessible caret support (which is handled within IAccessibleHandler), NVDA doesn't use hide events anywhere. Some web apps, such as Twitter, fire quite a few of these. Processing them is not only pointless, but it also degrades performance.
Contributor
|
Can I ask how you determined that hide events aren't used? Could be helpful advice for other nvda-devs. |
feerrenrut
approved these changes
Apr 30, 2020
Contributor
Author
|
Haha, nothing particularly ingenious:
git grep event_hide
and just in case we were watching for hide events in some other way:
git grep '"hide"'
git grep "'hide'"
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Link to issue number:
None.
Summary of the issue:
On twitter.com in Firefox, moving to tweets you haven't read yet by pressing j is pretty sluggish, taking upwards of 300 ms.
Description of how this pull request fixes the issue:
Twitter fires quite a few hide events in this case. Aside from IAccessible caret support (which is handled within IAccessibleHandler), NVDA doesn't use hide events anywhere. Processing them is not only pointless, but it also degrades performance. So, drop them.
Testing performed:
Refreshed Twitter, switched to focus mode and moved through tweets by pressing j. The timing is pretty variable, but before this PR, time since input shows > 300 ms most of the time. After this PR, time since input shows ~120 ms most of the time.
Known issues with pull request:
None.
Change log entry:
Probably not worth mentioning, since this is hardly blazing fast even with this PR.