当前位置: 首页 > news >正文

网站虚拟主机公司网站域名被抢注做商标

网站虚拟主机公司,网站域名被抢注做商标,聊城住房建设局网站,上海网站建设改版一些相关的总结,有点乱. UITableView是iOS中提供的用来以列的形式展示数据的视图,叫做表现图,但是只有一列,而且只能在垂直方向滚动.继承自UIScrollView. UITableView由多个分区组成(相当于班级的分组),每个分区由多行组成(相当于每个分组下的人). UITableView有两种样式,Plain…一些相关的总结,有点乱.  UITableView是iOS中提供的用来以列的形式展示数据的视图,叫做表现图,但是只有一列,而且只能在垂直方向滚动.继承自UIScrollView. UITableView由多个分区组成(相当于班级的分组),每个分区由多行组成(相当于每个分组下的人). UITableView有两种样式,Plain和Group样式,一旦设置之后,后期不能更改.     继承自UITableViewController 与 继承自UIViewController的区别. (UITableViewController是UIViewController的子类) .前者根视图是tableView, 而后者根视图是UIView. 前者不需要指定dataSource,delegate.服从协议. 而后者需要.前者不需要重写setEditing:animated:方法控制tableView进入编辑状态,而后者需要自己实现.前者对于UITableViewDataSource协议中的常用方法已经自动生成,而后者需要自己添加对应的方法.何时需要继承自UITableViewController?     当前页面信息的展示主要是以列的形式来展示的场景下, 都可以直接继承自UITableViewController.     在继承自UITableViewController的视图控制器中访问tableView.     1.self.view  根视图就是tableView.     2.self.tableView 有对应的tableView属性. UITableView协议中的一些方法 UITableViewDataSource协议   1.配置TableView一共有几个分组   - (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView;   2.配置tableView每个分区对应的行数     - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section;     3.配置用来显示每一行数据的cell.(UITableViewCell)     - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath; - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {//1.创建重用标识符.static NSString *identifier heihei;//2.根据重用标识符去重用队列中取可重用的cell.UITableViewCell *cell [tableView dequeueReusableCellWithIdentifier:identifier];//3.判断是否成功取到可重用的cell.cell是否为空.if (!cell) {//4.cell为空,说明没有成功取到cell.则创建一个cell.cell [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:identifier] autorelease];cell.accessoryType UITableViewCellAccessoryDisclosureIndicator; //辅助视图样式,小箭头 }NSDictionary *dic self.addressDic[self.sortedKeys[indexPath.section]][indexPath.row];cell.textLabel.text dic[name];cell.detailTextLabel.text dic[phone];cell.imageView.image [[UIImage imageNamed:dic[imageName]] scaleToSize:CGSizeMake(40, 40)];return cell; }       4.配置每个分区的页眉      - (NSString *)tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section;     5.配置tableView右侧的分区索引     - (NSArray *)sectionIndexTitlesForTableView:(UITableView *)tableView;     //编辑相关的协议方法     6.设置tableView的哪些行可以允许编辑     - (BOOL)tableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath;     7.提交编辑操作时触发(默认的时删除操作)     - (void)tableView:(UITableView *)tableView commitEditingStyle:(UITableViewCellEditingStyle)editingStyle forRowAtIndexPath:(NSIndexPath *)indexPath; //提交编辑操作, 对删除操作作出处理. - (void)tableView:(UITableView *)tableView commitEditingStyle:(UITableViewCellEditingStyle)editingStyle forRowAtIndexPath:(NSIndexPath *)indexPath {//总共分两步:1.修改数据源 2.修改界面//1.获取删除行对应的分区key.(是B分组,还是C分组)NSString *key self.sortedKeys[indexPath.section];//2.根据key获取对应的可变数组.NSMutableArray *group self.addressDic[key];if (editingStyle UITableViewCellEditingStyleInsert) {//处理插入操作//1.修改数据源NSDictionary *dic {name:Frank, age:18, gender:man, phone:110, imageName:};[group insertObject:dic atIndex:indexPath.row];//2.修改界面[tableView insertRowsAtIndexPaths:[indexPath] withRowAnimation:UITableViewRowAnimationRight];} else {//处理删除操作//需要判断是否要删除一个分区.if (group.count 1) {//删除分区//1.修改数据源//从字典中根据key移除对应的元素.[self.addressDic removeObjectForKey:key];//从排好序的key值数组中移除对应的key.[self.sortedKeys removeObject:key];//2.修改界面NSIndexSet *indexSet [NSIndexSet indexSetWithIndex:indexPath.section];[tableView deleteSections:indexSet withRowAnimation:UITableViewRowAnimationRight];} else {[group removeObjectAtIndex:indexPath.row]; //删除行对应的字典.//删除界面上的一行.[tableView deleteRowsAtIndexPaths:[indexPath] withRowAnimation:UITableViewRowAnimationRight];}} }       //移动相关的协议方法     8.设置tableView哪些行可以允许移动     - (BOOL)tableView:(UITableView *)tableView canMoveRowAtIndexPath:(NSIndexPath *)indexPath;     9.提交移动操作触发.     - (void)tableView:(UITableView *)tableView moveRowAtIndexPath:(NSIndexPath *)fromIndexPath toIndexPath:(NSIndexPath *)toIndexPath; //提交移动操作. - (void)tableView:(UITableView *)tableView moveRowAtIndexPath:(NSIndexPath *)sourceIndexPath toIndexPath:(NSIndexPath *)destinationIndexPath {//因为移动操作界面已经发生变化,我们只需要修改数据源即可.//1.获取到分区对应的数组.NSMutableArray *group self.addressDic[self.sortedKeys[sourceIndexPath.section]];//分区对应的数组//2.将原位置对应的元素取出来保存.NSDictionary *dic [group[sourceIndexPath.row] retain]; //retain 引用计数加1, 否则移除时就造成引用计数为0,空间回收了.//3.将原位置对应的元素删除掉.[group removeObjectAtIndex:sourceIndexPath.row];//4.将保存的元素插入到目的位置.[group insertObject:dic atIndex:destinationIndexPath.row];//5.释放所有权[dic release]; }       UITableViewDelegate协议     1.当tableView的行被选中时触发     - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath;     2.当tableView的行被取消选中时触发       - (void)tableView:(UITableView *)tableView didDeselectRowAtIndexPath:(NSIndexPath *)indexPath;     3.配置tableView某一行的高度     - (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath;     //编辑相关     4.设置tableView的编辑样式     - (UITableViewCellEditingStyle)tableView:(UITableView *)tableView editingStyleForRowAtIndexPath:(NSIndexPath *)indexPath;     5.设置删除时确认按钮的标题.     - (NSString *)tableView:(UITableView *)tableView titleForDeleteConfirmationButtonForRowAtIndexPath:(NSIndexPath *)indexPath;     //移动相关     6.设置tableView限制跨区移动     - (NSIndexPath *)tableView:(UITableView *)tableView targetIndexPathForMoveFromRowAtIndexPath:(NSIndexPath *)sourceIndexPath toProposedIndexPath:(NSIndexPath *)proposedDestinationIndexPath; - (NSIndexPath *)tableView:(UITableView *)tableView targetIndexPathForMoveFromRowAtIndexPath:(NSIndexPath *)sourceIndexPath toProposedIndexPath:(NSIndexPath *)proposedDestinationIndexPath {//sourceIndexPath 移动之前的位置//proposedDestinationIndexPath 即将要移动到的位置if (sourceIndexPath.section proposedDestinationIndexPath.section) {return proposedDestinationIndexPath;}return sourceIndexPath;}       UITableView编辑步骤:     1.在导航条上添加Edit按钮. 重写setEditing:Animated:方法. self.navigationItem.rightBarButtonItem self.editButtonItem;       2.控制tableView的可编辑状态.     3.设置tableView的哪些行可以允许编辑. (dataSource)     4.设置编辑样式. (delegate)     5.提交编辑操作. (dataSource) (1)修改数据源 (2)修改界面  转载于:https://www.cnblogs.com/ErosLii/p/4498881.html
http://wiki.neutronadmin.com/news/317365/

相关文章:

  • 想建立什么网站吗制作投票链接哪家好厂商
  • 重庆城乡建设网站外贸网站建设网站
  • 电子商务网站建设与管理实训心得建设网站时 首先要解决两个问题 一是什么
  • 公司网站建设费如何入账建站网址打不开
  • 大型网站多少钱企业建网站流程
  • 数据库里建设好的网站为什么外网进不去网站西安装修公司哪家好
  • vue可以做pc的网站湛江网站制作多少钱
  • 查询网站开发语言排号卡分销系统开发
  • 网站阵地建设管理办法ui动效网站
  • 黎平网站建设网站常见的风格
  • 百度指数 网站机械网站建设中心
  • 德阳中恒网站建设传奇霸主官方网站
  • 可以做网站的编程有什么软件东莞响应式网站哪里好
  • 网站开发工程师前景如何替换网站
  • 网站内容建设 互联互通wordpress 主题 最简单
  • 兰州建设工程信息网站html网站登录界面模板
  • 网站域名实名认证物业建设网站
  • 网站icp备案怎么做电商平台搭建方案
  • 宁波网站建设联系方法高密市建设局网站
  • 网站建设用模板个人网站 flash
  • 网站开发实战 王wordpress 访问缓慢
  • 个人能进行网站开发互联网项目网
  • 酒店网站建设一般考虑哪些因素沙朗做网站公司
  • php app网站建设访问网站 403.14错误
  • 免备案网站空间购买谷歌搜索引擎入口2022
  • 网站建设与管理实训心得怎么写网站服务器使用
  • 盐城市规划建设局网站微信网站建设开发
  • 做网站网站的代理算网站罪吗网站建设与推广合肥
  • 三步做一个抓娃娃机天津seo网站排名优化公司
  • 宁波网站建设caiyiduo有专门做ppt的网站有哪些