MCPcopy Create free account
hub / github.com/Chat2AnyLLM/code-agent-manager / clampCursor

Method clampCursor

internal/cli/tool_menu.go:156–165  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

154}
155
156func (s *pickerStep) clampCursor() {
157 v := s.filtered()
158 if len(v) == 0 {
159 s.cursor = 0
160 return
161 }
162 if s.cursor >= len(v) {
163 s.cursor = len(v) - 1
164 }
165}
166
167// toolMenuModel is the single-step tool picker. It now wraps a
168// pickerStep so the wizard can share the underlying list rendering.

Callers 1

updateMethod · 0.95

Calls 1

filteredMethod · 0.95

Tested by

no test coverage detected