When the keyboard is docked, UIKeyboardWillShowNotification
will be raised. If the keyboard is split or undocked, no keyboard notifications are raised.
If a keyboard is docked, UIKeyboardWillShowNotification
will be raised, and the following will be true:
[[[notification userInfo] valueForKey:@"UIKeyboardFrameChangedByUserInteraction"] intValue] == 1
If a keyboard is undocked, UIKeyboardWillHideNotification
will be raised, and the above statement will also be true.
Using this information has been adequate for me to code my user interface.
Note: this might be a violation of Apple's guidelines, I'm not sure.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…