tableview 底部 按钮按钮拖动不能点击,点击不能拖动

iOS&中&UITaleView&实现删除移动样式,当手指在每一行上滑动时,会出现删除按钮,并且点击可以实现相
& & #pragma mark & View
(void)viewDidLoad
[super viewDidLoad];
[mtableView setEditing:NO animated:YES];
(void)viewDidUnload
[super viewDidUnload];
(void)tableView:(UITableView *)tableView
commitEditingStyle:(UITableViewCellEditingStyle)editingStyle
forRowAtIndexPath:(NSIndexPath *)indexPath
NSLog(@"点击了编辑");
-(UITableViewCellEditingStyle)tableView:(UITableView *)tableView
editingStyleForRowAtIndexPath:(NSIndexPath *)indexPath
NSLog(@"手指撮动了");
return UITableViewCellEditingStyleD
&&& -(NSString
*)tableView:(UITableView *)tableView
titleForDeleteConfirmationButtonForRowAtIndexPath:(NSIndexPath
*)indexPath
return& @"编辑";
-(BOOL)tableView:(UITableView *)tableView
canEditRowAtIndexPath:(NSIndexPath *)indexPath
return YES;
(BOOL)tableView:(UITableView *)tableView
canMoveRowAtIndexPath:(NSIndexPath *)indexPath {
return YES;
(void)tableView:(UITableView *)tableView
moveRowAtIndexPath:(NSIndexPath *)fromIndexPath
toIndexPath:(NSIndexPath *)toIndexPath {
(BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
return (interfaceOrientation ==
UIInterfaceOrientationPortrait);
(NSInteger)tableView:(UITableView *)tableView
numberOfRowsInSection:(NSInteger)section
(UITableViewCell *)tableView:(UITableView *)tableView
cellForRowAtIndexPath:(NSIndexPath *)indexPath
UITableViewCell* cell = [tableView
dequeueReusableCellWithIdentifier:@"tag"];
if (cell==nil) {
&&&&&&&&&&&
cell = [[[UITableViewCell alloc]
initWithStyle:UITableViewCellStyleSubtitle
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
reuseIdentifier:@"tag"] autorelease];
cell.accessoryType=UITableViewCellAccessoryDisclosureI
cell.showsReorderControl=YES;
(CGFloat)tableView:(UITableView *)tableView
heightForRowAtIndexPath:(NSIndexPath *)indexPath
return 60;
&&& 打印的日志:
17:11:44.641 TAQDemo[] 手指撮动了
17:11:44.643 TAQDemo[] 手指撮动了
17:11:44.644 TAQDemo[] 手指撮动了
17:17:02.941 TAQDemo[] 点击了编辑
17:17:09.520 TAQDemo[] 手指撮动了
17:17:09.521 TAQDemo[] 手指撮动了
17:17:09.522 TAQDemo[] 手指撮动了
17:17:11.462 TAQDemo[] 点击了编辑
已投稿到:
以上网友发言只代表其个人观点,不代表新浪网的观点或立场。iOS 问题:求一个tableview
insert row的时候,cell能从tableview的最下面移动到相应的位置 -
求一个tableview
insert row的时候,cell能从tableview的最下面移动到相应的位置
登录后方可回答
耗时 0.0792 秒tableview点击不能拖动拖动不能点击_百度知道
tableview点击不能拖动拖动不能点击
继承CCTableView,扩展CCTableView的触摸函数,自己写个接口控制是否可以拖动。
能,详细说一下吗
来自团队:
其他类似问题
为您推荐:
table的相关知识
等待您来回答
下载知道APP
随时随地咨询
出门在外也不愁当前访客身份:游客 [
当前位置:
//关于cell上的收藏按钮
tableViewCell上面是一个滑动视图,还有一个按钮加到tableViewCell上,但不加在滑动视图上面,效果是,按钮不随滑动视图而滑动,位置固定,但怎么通过这个按钮获取当前的cell的行数?而且前提点击按钮并不会跳转页面,因为这是这个按钮要做收藏
共有0个答案
更多开发者职位上
有什么技术问题吗?
类似的话题

我要回帖

更多关于 ios tableview 按钮 的文章

 

随机推荐