I am trying to set up undo and redo for each textfield and unsure how to figure out how to determine which text field is the first responder.
Is there an argument I can pass into the methods called by the buttons from the toolbar, or do I need to do some fancy footwork?
This is an idea:
If the
viewControllerbecomes delegate of eachtextField, then theviewControllerwill get notified as eachtextField‘s value changes, or becomes first responder.To adopt the delegation, you will do:
Here is the reference to UITextFieldDelegate Protocol