Douban Photo Album Collection

Douban Photo Album Collection

Source code introduction

The source code of Douban Photo Collection comes from Tonny&Sunm. You can refer to it and use it after modification, but the interface cannot be used casually.
Source code running screenshot

Source code snippet:

  1. - (IBAction)showPhotosInAlbum:(UISwipeGestureRecognizer *)gesture {
  2. if (IsShowingCategory) return ;
  3.       
  4. CGPoint point = [gesture locationInView:_tableView];
  5. NSIndexPath *selectedIndexPath = [_tableView indexPathForRowAtPoint:point];
  6. if (!selectedIndexPath) return ;
  7.       
  8. NSUInteger row = selectedIndexPath.row;
  9.       
  10. [self hidePaperIndicator];
  11.       
  12. DAPhotoWallViewController *vc = (DAPhotoWallViewController *)[self.storyboard instantiateViewControllerWithIdentifier:@ "DAPhotoWallViewController" ];
  13.       
  14. NSDictionary *dic = _dataSource[@ "albums" ][row];
  15.       
  16. vc.albumDic = dic;
  17. NSArray *doubanCategory = [_appData valueForKeyPath:@ "cg_all" ];
  18. vc.canNotGotoUserAlbum = (_seletedCategory == doubanCategory.count);
  19.       
  20. CGFloat offset = [_tableView rectForRowAtIndexPath:selectedIndexPath].origin.y-[_tableView contentOffset].y;
  21. vc.paperIndicatorOffset = offset;
  22.   
  23. _lastSelectedRow = row;
  24. ////  
  25. UITableViewCell *cell = [_tableView cellForRowAtIndexPath:selectedIndexPath];
  26. UIView *view = [cell.contentView viewWithTag: 4 ];
  27. [UIView animateWithDuration: 0.3  
  28. animations:^{
  29. view.alpha = 1 ;
  30. }completion:^(BOOL finished) {
  31. [self.navigationController pushViewController:vc animated:YES];
  32. }];
  33. }

Source code link: http://download..com/data/1984620

<<:  Row-based waterfall view

>>:  Beautiful menu animation

Recommend

Case analysis: The operating model of "Lian Coffee"!

The user social growth system of "Growth Cof...

We drew what the "new classroom" of Tiangong Classroom looks like!

At 14:22 on July 24, China's space station...

In 2020, where will the wind of short video content marketing blow?

2019 is a year of "connecting the past and t...

Baidu snapshot hijacking tutorial, sharing of real cases of Baidu snapshot hijacking!

Maybe some friends still don’t know what “Baidu s...

How to create a hit product through online operation and promotion?

When it comes to hot-selling products, I believe ...

A guide to avoiding pitfalls from event promotion plan to implementation!

This article contains four parts: Essentially thi...

Musee d'Orsay: a concerto between technology and art

The Musée d'Orsay, which has been open to the...