에 UITable 스크롤 텍스트 필드 나는 UITableView
에서 UITextField
을 가지고 있고 나는 UITextField
클릭하고 때 그때는 오프셋 이동 한, 그러나 다음 필드로 사용자가 스크롤 한 후 약간의 시간 입력 새로 고침 이상한 행동을 보여 때 내 질문입니다 초점이 이전 UITextField
으로 되돌아갑니다.키보드
Q
키보드
0
A
답변
0
UR 프로젝트에 따르면, 코드와 impelement 참조
(BOOL) textFieldShouldBeginEditing (의 UITextField *)에 textField {
[자기 scrollViewToCenterOfScreen : TextField 구성];
return 예; }
(공극) scrollViewToCenterOfScreen (UIView의 *) theView {
CGFloat viewCenterY = theView.center.y;
CGRect applicationFrame = [[UIScreen mainScreen] applicationFrame];CGFloat availableHeight = applicationFrame.size.height - 200; // 키보드가 덮는 부분을 제거하십시오.
CGFloat y = viewCenterY - availableHeight/2.0;
if (y < 0) {
y = 0;
}
[scrollview setContentOffset : CGPointMake (0, y) animated : YES];
}
- (BOOL) textFieldShouldReturn : (UITextField에 *)에 textField {
if ([textField isEqual:txtStAppField])
{
[txtStConfirmField becomeFirstResponder];
}
else if ([textField isEqual:txtStConfirmField])
{
[txtDummyAppField becomeFirstResponder];
}
else if ([textField isEqual:txtStConfirmField])
{
[txtDummyConfirmFeild becomeFirstResponder];
}
else
{
[textField resignFirstResponder];
[scrollview setContentOffset:CGPointMake(0, 0) animated:YES];
}
return YES;
}
// txtStConfirmField, txtDummyConfirmFeild, txtDummyAppField, txtStConfirmField, txtStConfirmField는 tectField 있습니다 이름.
관련 문제
- 1. 키보드 입력 받기 키보드 외부에있는 C++ 프로그램
- 2. 화면 키보드 또는 가상 키보드 구성 요소
- 3. Android 용 맞춤 키보드 또는 가상 키보드
- 4. 키보드 이벤트
- 5. 맞춤 키보드
- 6. 키보드 식별
- 7. 키보드 자동화
- 8. 키보드 인터럽트
- 9. 가상 키보드
- 10. 키보드 아이폰
- 11. 키보드 이벤트
- 12. 키보드 처리 ++
- 13. 화면 키보드
- 14. 키보드 조작
- 15. 오버레이 키보드?
- 16. 이클립스 키보드
- 17. 하드웨어 키보드
- 18. iOS 및 키보드 검색 사용 중지 또는 키보드 입력
- 19. 가상 키보드 키를 가져 오기위한 Android 가상 키보드 KeyListener
- 20. 키보드 이벤트 발생, 웹킷 키보드 이벤트가 실행되지 않음
- 21. 키보드 및 키보드 색상의 백 워드를 변경하는 방법이 있습니까?
- 22. Android : 사용자 감지/키보드 입력 감지 (소프트 키보드)
- 23. iPad 키보드 '키보드 숨기기'버튼을 제거 할 수 있습니까?
- 24. 하나의 Windows 컨트롤에서 다른 키보드 컨트롤로 키보드 이벤트 전달
- 25. PHP의 키보드 입력
- 26. 키보드 탐색 JQuery와
- 27. Jquery를 사용한 키보드 탐색
- 28. 리눅스 콘솔 키보드 핸들러
- 29. 텍스트 뷰없이 iphone 키보드
- 30. iphone 일본어 키보드
@ user321373 : Jhaliya가 답변을 수락하고 나는 귀하의 질문을 수정하는 중 하나라고 말했고 귀하의 문제는 여전히 해결되지 않았습니다. –