Keyboard iOS 8自定义键盘(来自文本字段等)

Keyboard iOS 8自定义键盘(来自文本字段等),keyboard,ios8,ios-app-extension,Keyboard,Ios8,Ios App Extension,在新的iOS8自定义键盘扩展中,我们可以通过此代码转到下一个键盘 [self advanceToNextInputMode]; 如何取消自定义键盘?(不隐藏,不转到下一个键盘)。 谢谢你的帮助。:) 您可以使用UIInputViewController的dismissKeyboard方法。您可以使用UIInputViewController的dismissKeyboard方法。使用下面的代码 目标-C: [[UIApplication sharedApplication] sendAction

在新的iOS8自定义键盘扩展中,我们可以通过此代码转到下一个键盘

[self advanceToNextInputMode];
如何取消自定义键盘?(不隐藏,不转到下一个键盘)。
谢谢你的帮助。:)

您可以使用
UIInputViewController
dismissKeyboard
方法。

您可以使用
UIInputViewController
dismissKeyboard
方法。

使用下面的代码

目标-C:

[[UIApplication sharedApplication] sendAction:@selector(resignFirstResponder) to:nil from:nil forEvent:nil];
UIApplication.sharedApplication().sendAction("resignFirstResponder", to:nil, from:nil, forEvent:nil)
Swift:

[[UIApplication sharedApplication] sendAction:@selector(resignFirstResponder) to:nil from:nil forEvent:nil];
UIApplication.sharedApplication().sendAction("resignFirstResponder", to:nil, from:nil, forEvent:nil)
使用下面的代码

目标-C:

[[UIApplication sharedApplication] sendAction:@selector(resignFirstResponder) to:nil from:nil forEvent:nil];
UIApplication.sharedApplication().sendAction("resignFirstResponder", to:nil, from:nil, forEvent:nil)
Swift:

[[UIApplication sharedApplication] sendAction:@selector(resignFirstResponder) to:nil from:nil forEvent:nil];
UIApplication.sharedApplication().sendAction("resignFirstResponder", to:nil, from:nil, forEvent:nil)

好的老
辞职firstresponder
方法怎么了?好的老
辞职firstresponder
方法怎么了?