問題描述
我剛剛發現 scroll view
的新 keyboardDismissMode
屬性有一個惱人的錯誤.當將其與值為 UIScrollViewKeyboardDismissModeInteractive
的 text view
一起使用并且鍵盤被關閉時,scroll view
似乎會在繼續之前跳到頂部減速.
I've just found an annoying bug with the new keyboardDismissMode
property of the scroll view
. When using this with a text view
with the value UIScrollViewKeyboardDismissModeInteractive
and the keyboard is dismissed the scroll view
seems to jump up to the top before it continues to decelerate.
我已向 Apple 提交了錯誤報告,但需要解決方法.我已經嘗試了 DAKeyboardControl
沒有新的 iOS7
支持,它在幕后使用 keyboardDismissMode
并且它仍然這樣做,這對我來說表明了這一點是一個更深層次的問題.
I've filed a bug report with Apple but need a workaround. I've tried the DAKeyboardControl
without the new iOS7
support which behind the scenes is using the keyboardDismissMode
and it still does it which to me indicates this is a much deeper problem.
有什么建議嗎?
推薦答案
對于這個問題,你最好使用 scrollviewDelegete 進行編碼,并在你想通過 ResignFirstResponder 關閉鍵盤時簡單地提及
for this issue better you code with scrollviewDelegete and simply mention when you want dismiss keyboard through ResignFirstResponder
這篇關于UITextView 鍵盤DismissMode 錯誤的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!