文本字段未出现
Posted
技术标签:
【中文标题】文本字段未出现【英文标题】:TextFields not Appeared 【发布时间】:2012-11-19 11:44:29 【问题描述】:我是一名新的 ios 开发人员。我正在为字段设置动画,并且我想在字段中输入数据。我正在使用以下代码。
文字没有出现。它正在上升。请帮帮我。
if UIInterfaceOrientationIsLandscape(theStatusBarOrientation)
keyboardShiftAmount = keyboardFrame.size.width;
else
keyboardShiftAmount = keyboardFrame.size.height;
[UIView beginAnimations: @"ShiftUp" context: nil];
[UIView setAnimationDuration: keyboardSlideDuration];
NSLog(@"%f",keyboardShiftAmount);
self.view.center = CGPointMake(self.view.center.x,
self.view.center.y - keyboardShiftAmount);
[UIView commitAnimations];
viewShiftedForKeyboard = TRUE;
【问题讨论】:
【参考方案1】:使用uitextfielddelegate制作动画
【讨论】:
以上是关于文本字段未出现的主要内容,如果未能解决你的问题,请参考以下文章