Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can sliding UITableViewCells be implemented?

I have a UITableView that is populated with a friendslist, i understand how to select a cell and make it go to a whole new viewcontroller, but how would i create the effect of only changing the cell that was selected, for example.

i want to select a cell, (using a gesture by swiping from left to right). Then slide a new cell over with a few labels/buttons that a user can interact with.

Your time and help is much appreciated. I dont even know where to start on this, i have googled a few things and gotten a few links suck as This one that explains Reload, Re-paint and re-layout but im still not quite understanding that.

EDIT

after a little further research of checking the right side of stackoverflow i found a very useful post and source code here, im going to try this out and see if this is what im looking for, or if anyone can confirm for me that would be great. Sorry in advance for wasting stackoverflows space if this is what i was looking for.

like image 419
NodeDad Avatar asked Dec 10 '25 20:12

NodeDad


1 Answers

You can use the post that you found on S/O with the source code, but alternatively you can look towards the various open source projects which provide the functionality you are looking for. Furthermore, there is a great tutorial here about how the such can be implemented: http://idevrecipes.com/2011/04/14/how-does-the-twitter-iphone-app-implement-side-swiping-on-a-table/

Open Source:

  • https://github.com/lukeredpath/LRSlidingTableViewCell
  • https://github.com/malcommac/DMSlidingCell
  • https://github.com/jakeboxer/JBSlidingTableViewCell

You can find more here: https://github.com/search?q=sliding+uitableviewcell&type=Repositories&ref=advsearch&l=Objective-C

like image 85
max_ Avatar answered Dec 12 '25 09:12

max_