简体   繁体   English

UIPageViewController错误与UITextField和键盘显示

[英]UIPageViewController bug with UITextField and keyboard showing

So I'm trying to find a workaround for this bizarre bug: http://www.screencast.com/t/UqvVn8ccodEV 所以我试图找到这个奇怪的错误的解决方法: http//www.screencast.com/t/UqvVn8ccodEV

Basically I have a UIPageViewController with sub view controllers (obviously). 基本上我有一个带子视图控制器的UIPageViewController(显然)。 Once I add a text field, it does this weird thing where if you scroll it and then click a text field, it randomly moves to another page. 一旦我添加了一个文本字段,就会发生这种奇怪的事情,如果你滚动它然后单击一个文本字段,它会随机移动到另一个页面。 None of the delegates get called, and the keyboard moves up and down again. 没有任何代表被调用,键盘再次上下移动。

Seems like the same thing as here: clicking/typing on UITextField increments UIPageViewController instead of displaying keyboard 看起来像这里一样: 在UITextField上点击/输入增加UIPageViewController而不是显示键盘

Also seems to be recorded here: http://openradar.appspot.com/13315308 似乎也记录在这里: http//openradar.appspot.com/13315308

Can't figure out what the hell this would be, or a way around it. 无法弄清楚这到底是什么,或者绕过它。

Edit 编辑

Here is a skeleton version (pulled from the linked question): https://www.dropbox.com/s/6l5efem3wque7li/pageScroll.zip?v=1mci 这是一个骨架版本(从链接的问题中提取): https//www.dropbox.com/s/6l5efem3wque7li/pageScroll.zip?v = 1mci

Scroll one page, then hit the textfield. 滚动一页,然后点击文本字段。 Only happens the first time around. 只有第一次出现。

Check this voodoo out: Embed your UITextField within a UIScrollView . 检查这个voodoo:将UITextField嵌入UIScrollView I tried it on the project you referred to and it worked. 我在你提到的项目上尝试了它并且它有效。

I guess it has something to do with changing the responder chain that messes things up. 我想这与改变响应者链有关,这会让事情变得混乱。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM