密码自动填充快速键在ios 11中 [英] password autofill quicktype bar in ios 11
问题描述
在ios 11中引入了一项新功能:适用于app的密码自动填充功能。
此功能允许用户直接通过键盘快速键栏在他们的应用中使用他们保存的密码。
In ios 11 a new feature is introduced: Password Autofill for app. This feature allows users to use their saved password in their apps directly from the keyboard quicktype bar.
https://code.tutsplus.com/articles/faster-logins-with-password-autofill-in-ios-11--cms-29096
https://developer.apple.com/videos/play/ wwdc2017 / 206 /
但问题是当我使用keyboardWillShow或keyboardWillHide或keyboardDidShow或keyboardDidHide事件时,他们都没有考虑keyboa的快速高度rdSize。
But the problem is when I use keyboardWillShow or keyboardWillHide or keyboardDidShow or keyboardDidHide events none of them consider the quickbar height for keyboardSize.
- (void)keyboardWillShow:(NSNotification *)notification {
NSDictionary* info = [notification userInfo];
CGSize keyboardSize = [info[UIKeyboardFrameBeginUserInfoKey] CGRectValue].size;
}
keyboardSize将是之前的keyboardSize所以如果我们有快速栏,现在它是它消失了,keyboardSize比它应该更多,反之亦然。
似乎在快速栏显示/隐藏之前会触发keyboardWillShow通知。
keyboardSize would be the previous keyboardSize so if we had the quickbar and now it is disappeared it keyboardSize is more than it should be and vice versa. It seems that keyboardWillShow notification fires before the quickbar show/hide.
如果有人知道如何在快速栏显示/隐藏或任何其他后触发键盘通知建议,请分享。
If anybody has any idea how to fire keyboard notifications after quickbar show/hide or any other suggestion, please share.
谢谢..
推荐答案
尝试使用 UIKeyboardFrameEndUserInfoKey
dont UIKeyboardFrameBeginUserInfoKey
try to useUIKeyboardFrameEndUserInfoKey
dont UIKeyboardFrameBeginUserInfoKey
这篇关于密码自动填充快速键在ios 11中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!