Lines Matching refs:click_pos
700 int* click_pos) const { in RetokenizeAndFindClick()
706 only_use_line_with_click, tokens, click_pos); in RetokenizeAndFindClick()
714 std::vector<Token>* tokens, int* click_pos) const { in RetokenizeAndFindClick()
727 if (click_pos == nullptr) { in RetokenizeAndFindClick()
728 click_pos = &local_click_pos; in RetokenizeAndFindClick()
730 *click_pos = FindCenterToken(input_span, *tokens); in RetokenizeAndFindClick()
731 if (*click_pos == kInvalidIndex) { in RetokenizeAndFindClick()
734 *click_pos = internal::CenterTokenFromClick(input_span, *tokens); in RetokenizeAndFindClick()
741 std::vector<Token>* tokens, int* click_pos) { in StripOrPadTokens() argument
743 if (*click_pos + right_context_needed + 1 >= tokens->size()) { in StripOrPadTokens()
746 context_size, static_cast<int>(*click_pos + right_context_needed + 1 - in StripOrPadTokens()
750 } else if (*click_pos + right_context_needed + 1 < tokens->size() - 1) { in StripOrPadTokens()
753 std::advance(it, *click_pos + right_context_needed + 1); in StripOrPadTokens()
758 if (*click_pos < left_context_needed) { in StripOrPadTokens()
761 std::min(context_size, left_context_needed - *click_pos); in StripOrPadTokens()
764 *click_pos += num_pad_tokens; in StripOrPadTokens()
765 } else if (*click_pos > left_context_needed) { in StripOrPadTokens()
768 std::advance(it, *click_pos - left_context_needed); in StripOrPadTokens()
769 *click_pos -= it - tokens->begin(); in StripOrPadTokens()