내 iPhone 앱에서 내 UITextFields에 문제가있어 다른 사용자가 이전에 보았 으면합니다.UITextField 편집 문제 - iPhone SDK
화면에 몇 개의 UITextField가 있습니다. 탭을하면 키보드가 표시됩니다. 내가 편집 갈 때 그러나, (돋보기를 얻기 위해 아래로 화면을 잡아), 그것은 좋은하지 않습니다
-(void)moveViewUpFromValue:(float)fromOldValue toNewValue:(float)toNewValue keep:(BOOL)keep {
CABasicAnimation *theAnimation;
theAnimation=[CABasicAnimation animationWithKeyPath:@"transform.translation.y"];
theAnimation.duration=0.25;
theAnimation.repeatCount=1;
if(keep) {
[theAnimation setRemovedOnCompletion:NO];
[theAnimation setFillMode:kCAFillModeForwards];
}
theAnimation.fromValue=[NSNumber numberWithFloat:fromOldValue];
theAnimation.toValue=[NSNumber numberWithFloat:toNewValue];
[self.view.layer addAnimation:theAnimation forKey:@"animateLayer"];
}
이 시각적으로, 작품이를 극복하기 위해, 나는 함께 이동보기 애니메이션 나타나다. 상호 작용은 이동하기 전에 위치에 유지됩니다.
여기에 어떤 일이 벌어 질 수 있으리라 생각합니다.
많은 감사, 브렛
그게 전부입니다. 무리 감사! 조금 더 살펴본 결과, [UIView beginAnimations ...]가 아마도 가장 좋은 방법 일 것입니다. – Brett