MCPcopy
hub / github.com/codeaashu/claude-code / moveFocus

Function moveFocus

src/ink/selection.ts:442–450  ·  view source on GitHub ↗
(s: SelectionState, col: number, row: number)

Source from the content-addressed store, hash-verified

440 * keeps the off-screen rows. Caller supplies coords already clamped/wrapped.
441 */
442export function moveFocus(s: SelectionState, col: number, row: number): void {
443 if (!s.focus) return
444 s.anchorSpan = null
445 s.focus = { col, row }
446 // Explicit user repositioning — any stale virtual focus (from a prior
447 // shiftSelection clamp) no longer reflects intent. Anchor stays put so
448 // virtualAnchorRow is still valid for its own round-trip.
449 s.virtualFocusRow = undefined
450}
451
452/**
453 * Shift anchor AND focus by dRow, clamped to [minRow, maxRow]. Used for

Callers 1

moveSelectionFocusMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected