fix: terminal flicker regression — viewport clear inside dimension guard#51
Open
TeigenZhang wants to merge 1 commit intoArk0N:masterfrom
Open
fix: terminal flicker regression — viewport clear inside dimension guard#51TeigenZhang wants to merge 1 commit intoArk0N:masterfrom
TeigenZhang wants to merge 1 commit intoArk0N:masterfrom
Conversation
…on guard Three fixes from the WIP flicker branch that were lost during master merges: 1. Move viewport clear (\x1b[3J\x1b[H\x1b[2J) inside the dimension-change guard so it only fires when cols/rows actually change. Previously every resize event cleared the screen even at identical dimensions, causing visible flicker with no subsequent Ink redraw to repaint. 2. Sync _lastResizeDims in sendResize() so restoreTerminalSize() doesn't trigger a redundant viewport clear on the next throttledResize tick. 3. Add didScroll tracking to touch events — tap (no scroll) now refocuses xterm's hidden textarea, fixing mobile keyboard input routing after tapping the terminal area.
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.
Summary
\x1b[3J\x1b[H\x1b[2J) inside the dimension-change guard — previously every resize event cleared the screen even at identical dimensions, causing visible flicker with no Ink redraw to repaint_lastResizeDimsinsendResize()to prevent redundant viewport clears afterrestoreTerminalSize()didScrolltracking to touch events so tap-without-scroll refocuses xterm's hidden textarea, fixing mobile keyboard input routingTest plan
restoreTerminalSize(Ctrl+Shift+R), verify no double-clear flicker🤖 Generated with Claude Code