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

Fix all x-model highlight flickering #224415

Merged
merged 1 commit into from
Jul 31, 2024
Merged

Fix all x-model highlight flickering #224415

merged 1 commit into from
Jul 31, 2024

Conversation

Yoyokrazy
Copy link
Contributor

@Yoyokrazy Yoyokrazy commented Jul 31, 2024

Fixes: #224321

With the new parameter inside the wordHighlighter's run() and stopAll() fxns, we can preserve decorations on models as we respond to new highlight requests from different events.

No more flickering on settings change, due to only driving new worker requests from a single editor, and also preserving highlights upon changing between single and multifile highlight settings.

Also a new delayer to avoid running a highlight req for both editor focus and cursor position changes. Previously, this would occur when switching back to a previously focused window, and also putting a cursor in a new position. This would trigger an editor focus event, and then immediately trigger a cursor change event. Now, only 1 run() will be triggered. This also preserves the fix for the issue where you click back into the EXACT SAME cursor position into a previous tab. Rare, but it happens.

@Yoyokrazy Yoyokrazy self-assigned this Jul 31, 2024
@vscodenpa vscodenpa added this to the August 2024 milestone Jul 31, 2024
@Yoyokrazy Yoyokrazy enabled auto-merge (squash) July 31, 2024 17:50
@Yoyokrazy Yoyokrazy merged commit 79327ff into main Jul 31, 2024
7 checks passed
@Yoyokrazy Yoyokrazy deleted the fun-aspen branch July 31, 2024 17:54
@vs-code-engineering vs-code-engineering bot locked and limited conversation to collaborators Sep 14, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Highlights flicker on settings change for x-model occurrences
3 participants