iOS開發 ----- 仿QQ實現滑動顯示後邊按鈕

仿QQ實現滑動顯示後邊按鈕

代碼傳送門

簡介

滑動cell之後,會顯示按鈕,然後可以實現刪除功能

這只是一個簡單的工程,並不是一個框架或者庫之類的

想使用的話,可以導入MyTableViewCell.m MyTableViewCell.h到工程中

然後遵守協議,實現自己的方法即可

默認有三個按鈕,可以根據自己的需求增刪

@protocol MyTableViewCellButtonDelegate <NSObject>

@required

-(void)cellClickSection:(NSInteger)section row:(NSInteger)row;

@optional
-(void)delButtonClickSection:(NSInteger)section row:(NSInteger)row;
-(void)addButtonClickSection:(NSInteger)section row:(NSInteger)row;
-(void)checkButtonClickSection:(NSInteger)section row:(NSInteger)row;

@end

效果圖

這裏寫圖片描述

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章