NSIndexSet-入门浅析记得上一次,用到,关于删除UITableView分组的方法[tableViewdeleteSections:[NSIndexSetindexSetWithIndex:indexPath.section]withRowAnimation:UITableViewRowAni...
分类:
其他好文 时间:
2014-12-12 16:30:10
阅读次数:
239
转载自:http://chinaxxren.iteye.com/blog/1224223-、建立 UITableView DataTable = [[UITableView alloc] initWithFrame:CGRectMake(0, 0, 320, 420)]; [DataTable se...
分类:
其他好文 时间:
2014-12-12 14:37:19
阅读次数:
152
- (void) tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{ // 取消前一个选中的,就是单选啦 NSIndexPath *lastIndex = [NS...
分类:
其他好文 时间:
2014-12-11 18:53:43
阅读次数:
141
iOS开发系列--UITableView全面解析--UIKit之UITableView概述在iOS开发中UITableView可以说是使用最广泛的控件,我们平时使用的软件中到处都可以看到它的影子,类似于微信、QQ、新浪微博等软件基本上随处都是UITableView。当然它的广泛使用自然离不开它强大的...
分类:
移动开发 时间:
2014-12-11 12:17:22
阅读次数:
226
在iOS8中会发现分割线默认是没有全部显示的,在iOS7中适用的代码if ([self.myCardTableView respondsToSelector:@selector(separatorInset)]) { self.myCardTableView.separatorInse...
分类:
移动开发 时间:
2014-12-11 10:06:41
阅读次数:
169
一、UITableView的属性NSIndexPath类型是用来获取用户选择的indexPath,在别的函数里面,若需要知道用户选择了哪个cell,用上它可以省事很多。不必再去建全局变量section和row。NSIndexPath *tableSelection = [self.tableView...
分类:
其他好文 时间:
2014-12-11 10:02:16
阅读次数:
202
当 UITableView 中有一个 label 的内容比较长的时候,就需要 cell 自适应高度来多行展示label;首先设置 label 的 line 为0;代码如下:// 为每一个 cell 预设置一个高度,可以提高效率- (CGFloat)tableView:(UITableView *)...
分类:
移动开发 时间:
2014-12-10 22:35:18
阅读次数:
218
UITableView的详细使用 UITableView是app开发中常用到的控件,功能很强大,多用于数据的显示。下面以一个简单的实例来介绍tableview的基本用法。(适合新手,高手飘过)@interfaceTableViewTestViewController :UIViewControll....
分类:
其他好文 时间:
2014-12-10 21:02:27
阅读次数:
379
多选做法如下:
- (void)tableView:(UITableView *)tableViewdidSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
[tableViewdeselectRowAtIndexPath:indexPath animated:YES];
Custom *cell= (Custom*...
分类:
移动开发 时间:
2014-12-10 16:17:13
阅读次数:
216
问题背景:
需要在UITableView中的每一行下载图片,之前使用placeholder,下载好后存在cache中。
解决方案:
方案一:
使用SDWebImage:https://github.com/rs/SDWebImage
如何安装及使用在git页面有详细解释,具体使用的代码:
#import
...
- (UITableViewCell *)tableView...
分类:
移动开发 时间:
2014-12-10 00:34:03
阅读次数:
292