成人免费xxxxx在线视频软件_久久精品久久久_亚洲国产精品久久久_天天色天天色_亚洲人成一区_欧美一级欧美三级在线观看

以行為主的瀑布流視圖

移動開發
demo展示以行為主(row)的瀑布流樣式視圖,只支持ARC模式。

源碼簡介

demo展示以行為主(row)的瀑布流樣式視圖,只支持ARC模式。

源碼截圖:

[[128131]]

源碼片段:

  1. - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath 
  2.     BDRowInfo *ri = [_rowInfos objectAtIndex:indexPath.row]; 
  3.     static NSString *CellIdentifier = @"Cell"
  4.     BDDynamicGridCell *cell = [tableView dequeueReusableCellWithIdentifier:[CellIdentifier stringByAppendingFormat:@"_viewCount%d", ri.viewsPerCell]]; 
  5.       
  6.     if (!cell) { 
  7.         cell = [[BDDynamicGridCell alloc] initWithLayoutStyle:BDDynamicGridCellLayoutStyleFill 
  8.                                               reuseIdentifier:CellIdentifier]; 
  9.           
  10.         cell.viewBorderWidth = 1
  11.           
  12.         UILongPressGestureRecognizer *longPress = [[UILongPressGestureRecognizer alloc] initWithTarget:self action:@selector(didLongPress:)]; 
  13.         longPress.numberOfTouchesRequired = 1
  14.         [cell.gridContainerView addGestureRecognizer:longPress]; 
  15.           
  16.         UITapGestureRecognizer *doubleTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(didDoubleTap:)]; 
  17.         doubleTap.numberOfTapsRequired = 2
  18.         doubleTap.delaysTouchesBegan = YES; 
  19.         [cell.gridContainerView addGestureRecognizer:doubleTap]; 
  20.           
  21.         UITapGestureRecognizer *singleTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(didSingleTap:)]; 
  22.         singleTap.numberOfTapsRequired = 1
  23.         singleTap.delaysTouchesBegan = YES; 
  24.         [cell.gridContainerView addGestureRecognizer:singleTap]; 
  25.         [singleTap requireGestureRecognizerToFail:doubleTap]; 
  26.     } 
  27.       
  28.     //clear for updated list of views 
  29.     [cell setViews:nil]; 
  30.     cell.viewBorderWidth = self.borderWidth; 
  31.     cell.backgroundColor = nil; 
  32.   
  33.     cell.rowInfo = ri; 
  34.     NSArray * viewsForRow = [NSArray array]; 
  35.     for (int i=0; i<ri.viewspercell; i++)="" {="" viewsforrow="[viewsForRow" arraybyaddingobject:[self.delegate="" viewatindex:i="" +="" ri.accumulatedviews="" rowinfo:ri]];="" }="" nsassert(viewsforrow.count=""0, @"number of views per row must be greater than 0"); 
  36.     [cell setViews:viewsForRow]; 
  37.       
  38.     return cell; 
  39. }</ri.viewspercell;> 

源碼鏈接:http://down.51cto.com/data/1984619

責任編輯:chenqingxiang 來源: 網絡整理
相關推薦

2021-08-13 10:28:18

IT領導者CIO業務

2012-07-30 09:48:32

設計管理

2024-09-03 17:04:15

前端算法布局

2012-05-02 13:53:00

JavaScript

2011-03-14 15:56:37

NoSQL

2024-08-19 14:01:00

2021-08-05 12:48:17

谷歌信息泄露漏洞

2013-01-15 18:26:36

教育信息化

2016-06-23 19:45:06

青云QingCloudQingCloud I

2009-02-20 10:14:32

NehalemCore i7英特爾

2012-06-15 09:35:42

JavaScript

2013-04-03 15:45:51

Android瀑布流android_wat

2022-05-27 16:40:24

軟件開發DevSecOps

2021-04-17 10:29:18

DDoSDDoS攻擊RDoS活動

2013-01-08 09:32:46

SaaSOracleSAP

2015-02-02 16:21:26

android瀑布流圖片加載

2021-07-09 14:21:50

惡意軟件REvil網絡攻擊

2013-05-09 10:18:28

鮑爾默Azure微軟

2017-12-25 13:47:59

云計算多云混合云

2011-12-31 21:19:56

App Store
點贊
收藏

51CTO技術棧公眾號

主站蜘蛛池模板: 欧美日韩视频在线播放 | 亚洲成人一级 | 亚洲综合大片69999 | 日韩欧美电影在线 | 激情六月丁香 | 91精品久久 | 日韩一区二区精品 | 黄视频网站在线 | 小川阿佐美pgd-606在线 | 毛片网站免费观看 | 日本免费一区二区三区 | 日韩1区2区 | 91精品久久久 | 国产一区二区三区免费 | 自拍偷拍第1页 | 欧美日韩久久精品 | 欧美精品中文字幕久久二区 | 国产欧美一区二区精品久导航 | 一级黄色网页 | 亚洲一区高清 | 91精品国产综合久久久久久蜜臀 | 毛片网站在线观看视频 | 国产xxxx岁13xxxxhd| 高清一区二区三区 | 一区二区三区免费 | www.欧美.com| 99久久精品国产毛片 | 日本不卡视频 | 亚洲视频中文字幕 | 久久久区| 91色视频在线观看 | 中文字幕乱码一区二区三区 | 成人精品国产免费网站 | 成人h视频在线观看 | 在线免费观看毛片 | 国产在线成人 | h片在线免费观看 | 成人亚洲综合 | 亚洲九九 | 亚洲狠狠爱 | 国产伦精品一区二区三区精品视频 |