Beautiful menu animation

Beautiful menu animation

Source code introduction

You can add beautiful animated content to the app's menu, customize the icon and title, and design cells and layouts according to your preferences.
Source code running screenshot

Source code snippet:

  1. - (IBAction)presentMenuButtonTapped:(UIBarButtonItem *)sender {
  2. // init YALContextMenuTableView tableView  
  3. if (!self.contextMenuTableView) {
  4. self.contextMenuTableView = [[YALContextMenuTableView alloc]initWithTableViewDelegateDataSource:self];
  5. self.contextMenuTableView.animationDuration = 0.15 ;
  6. //optional - implement custom YALContextMenuTableView custom protocol  
  7. self.contextMenuTableView.yalDelegate = self;
  8.           
  9. //register nib  
  10. UINib *cellNib = [UINib nibWithNibName:@ "ContextMenuCell" bundle:nil];
  11. [self.contextMenuTableView registerNib:cellNib forCellReuseIdentifier:menuCellIdentifier];
  12. }
  13.   
  14. // it is better to use this method only for proper animation  
  15. [self.contextMenuTableView showInView:self.navigationController.view withEdgeInsets:UIEdgeInsetsZero animated:YES];
  16. }
  17.   
  18. #pragma mark - Local methods
  19.   
  20. - ( void )initiateMenuOptions {
  21. self.menuTitles = @[@ "" ,
  22. @ "Send message" ,
  23. @ "Like profile" ,
  24. @ "Add to friends" ,
  25. @ "Add to favorites" ,
  26. @ "Block user" ];
  27.   
  28. self.menuIcons = @[[UIImage imageNamed:@ "Icnclose" ],
  29. [UIImage imageNamed:@ "SendMessageIcn" ],
  30. [UIImage imageNamed:@ "LikeIcn" ],
  31. [UIImage imageNamed:@ "AddToFriendsIcn" ],
  32. [UIImage imageNamed:@ "AddToFavouritesIcn" ],
  33. [UIImage imageNamed:@ "BlockUserIcn" ]];
  34. }

Source code download: http://download..com/data/1984622

<<:  Douban Photo Album Collection

>>:  OS X, iOS and Linux all have more vulnerabilities than Windows

Recommend

Iris recognition - the ID card hidden in the eyes

ID card Everyone must be familiar with But do you...

What are the most cost-effective APP promotion methods?

This topic is not my best, because most of my pre...

Low cost and high activity, how to recall users?

What I will talk about today is mainly related to...

Event Operations: Grasp these 5 points to increase online event participation

A popular online event can not only directly brin...

Uncover the secrets of Tik Tok’s explosive growth and addiction!

In the past six months, especially during the epi...

College Entrance Examination Graduation Season Topic Marketing

How to do topic marketing during the college entr...

What do target keywords mean? What are target keywords?

Target keywords refer to the "main" key...