objective c - iPad; TableView full of arbitrary number of text fields and buttons in different rows. resignFirstResponder on all textfields when button is pressed? -


ipad:

i have tableview full of arbitrary number of text fields , buttons in different rows.

when press button modal popup popup. if press button while editing text field (and keyboard displayed on ipad) hilarious happen. popover 75% off corner of screen (with quarter visible in quarter.)

to avoid bad behavior, how resignfirstresponder on textfields in table when button pressed?

you can implement method:

-(bool)textfieldshouldreturn:(uitextfield *)textfield {      [textfield resignfirstresponder];      return yes; } 

as long textfields' delegate current view controller, should work fine :)


Comments

Popular posts from this blog

php - What is the difference between $_SERVER['PATH_INFO'] and $_SERVER['ORIG_PATH_INFO']? -

fortran - Function return type mismatch -

queue - mq_receive: message too long -