inputAccessoryView dismisses, but keyboard won't? - iphone

I have a UITextView with an inputAccessoryView that contains a toolbar with a "Done" button so that the user can end the editing process. Inside the method fired by pressing the Done button, I call resignFirstResponder on the UITextView to dismiss the keyboard.
So when I tap "Done", the accessory view disappears, but the keyboard itself remains. I am completely stumped as to why this might be happening, or where to start looking. This app is running on iPad with iOS 5.1
Any ideas?
Thanks! //Scott

Related

resignFirstResponder Leaves Keyboard Behind

iPhone app.
I have a simple view with UITextView as first responder. I resign first responder and pop to the previous controller but the keyboard stays. Textview doesn't even exist anymore but the keyboard is still visible.
The controller that I pop to is a tableview, no objects that can even assume first responder status. So the keyboard is just there obscuring half my table and there is not even a way to dismiss it. I have to navigate back to a view that has a text box or textview, select one and dismiss that in order to get rid of the keyboard.
How is this possible?
On viewWillAppear just write
[self.view endEditing:YES];

clicking/typing on UITextField increments UIPageViewController instead of displaying keyboard

I'm using UIPageViewController to show View Controllers that are on my storyboard on the screen, when I put a UITextField on the view controller that I've put on the UIPageViewController and when I run te app and I click on the UITextField, the screen jumps to the next screen instead of just popping up the keyboard or when you type something in the UITextField, it also jumps to the next screen. I've made a simple sample project which you can download here: http://www.2shared.com/file/VNF3DO-g/pageScroll.html use iPhone simulator and click on the UITextField and you'll see it will jump to the next view instead of popping up the keyboard.

Keyboard won't appear in modal view controller

I have a UIWebView in a modal view controller (using SVModalViewController). In iOS 4.2, when I tap on an input text field, the keyboard does not appear. The view animation where the page scrolls to make room for the keyboard still happens, but nothing appears. It works fine in iOS 5.
I am calling [self.window makeKeyAndVisible] in the application delegate, so that is not the issue.
Any guidance would be very much appreciated!
Solution: I needed to make the view controller containing the UIWebView the first responder, and after that, it worked!

UIModalView Dismisses stranger when keyboard is active

I'm having a strange issue with my modal view. The modal view asks for some user input so the keyboard pops on. When I click the cancel button to dismiss while the keyboard is still active they both dismiss in an animated fashion but the modal jerks to the right first, very strange. What would be my best course of action here? Would it be to disable my cancel modal button when the keyboard is active? If so how do I go about detecting the presents of the keyboard?
Thanks!
You can detect the presence of keyboard using NSNotification Class. Hope this helps

Pressing UINavigationController back button while typing

I recently discovered that if a UITextField is being edited in a controller that's attached to a UINavigationController and the back button is pressed, upon returning to this controller, the DidBeginEditing function is called again and the UITextField keyboard is brought back up. I was wondering if there's a way to stop the keyboard from coming back up. Maybe there's a way to hook the back button so it doesn't save the fact that the text field is being edited.
Implement viewWillDisappear: on the view controller that controls the text field, and call:
[theTextField resignFirstResponder];
This will dismiss the keyboard.

Categories