Closed focusedonfit closed 8 years ago
@focusedonfit
When user taps on UITextView
in your view controller(XLFormViewController
instance) will be called inputAccessoryViewForRowDescriptor:
method. In this method you can check the tag
of your rowDescriptor
instance and return
view that you need.
Don't forget to return [super inputAccessoryViewForRowDescriptor:rowDescriptor];
to save base inputAccessoryView
for other cells.
I can set the view of my inputAccessory OK. But I'm trying to hook up the buttons in the view. For example, I have a button that I want to add '5' to whatever number is currently in the textview.
@focusedonfit You can get current 'responder' of your form and do whatever you want using '[self.tableView findFirstResponder]'. In this case you can add button to 'inputAccessoryView' and as action get responder cell, set/update/add value of 'rowDescriptor' call '- (void)update' method of cell to flush changes in UI.
I have a custom input accessory view that I want to get the current text in the UITextView and then change it as well. What is the best way to accomplish this?
Thank you