ios - How to add a plus button in a navigation bar when the edit button is pressed? -
i writing simple app tableview controller. view has navigation bar, , has edit button. add plus button in top left corner when content being edited , edit button has been pressed.
i added button using following prewritten code:
// uncomment following line display edit button in navigation bar //this view controller. self.navigationitem.rightbarbuttonitem = self.editbuttonitem()
i don't know if there method called when edit button created pressed, think solve problem created add plus button in method.
override setediting:animated:
on view controller. it'll called everytime editing state changes.
make sure call super first.
Comments
Post a Comment