I have a toolbar which I need to use when editing text, and when not.
In previous apps, I've moved the toolbar manually (listening for notifications, etc.)
But I want to use inputAccessoryView
... so in my viewDidLoad
, I do
for (/*myTextFields*/) {
textField.inputAccessoryView = keyboardToolbar;
}
[self.view addSubView:keyboardToolbar];
Which works fine, the toolbar appears, I click on a text field, toolbar slides up - all good.
But when I then hide the keyboard, inputAccessoryView
drags my toolbar off the screen. Is there any way to tell the inputAcessoryView
where it's fixed location is? - Or do I have to go back to my old way of listening for notifications etc...?