2015-04-10 14 views

risposta

12

eliminare Sì, implementare la funzione di UITableViewDelegate:

func tableView(tableView: UITableView, titleForDeleteConfirmationButtonForRowAtIndexPath indexPath: NSIndexPath) -> String! { 
     return "your string" //or customize for each indexPath 
} 
0

titleForDeleteConfirmationButtonForRowAt delegato presente in UITableViewDelegate può essere utilizzato per modificare il testo di "Elimina" nella cella tableview.

func tableView(_ tableView: UITableView, titleForDeleteConfirmationButtonForRowAt indexPath: IndexPath) -> String? { 
    return NSLocalizedString("erase".localized, comment: "") 
} 
Problemi correlati