[TIMOB-15596] iOS7: Support built in functionality to add "More" button(s) when user swipe to delete a cell in rows
GitHub Issue | n/a |
Type | New Feature |
Priority | High |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2015-03-06T21:52:34.000+0000 |
Affected Version/s | n/a |
Fix Version/s | 2014 Sprint 06, 2014 Sprint 06 SDK, Release 4.1.0 |
Components | iOS |
Labels | supportTeam |
Reporter | Eduardo Gomez |
Assignee | Vishal Duggal |
Created | 2013-10-28T16:34:13.000+0000 |
Updated | 2015-07-07T20:51:54.000+0000 |
Description
Request description
Like in iOS7 Default Mail app, on swipe left the table view row will show options "More" and "Trash" which on click will prompt optional dialog to pursue the action.
Feature Request
Titanium Developers would like to request built in functionality for this custom behaviour in upcoming release since many of latest apps requires such a functionality of showing more than one button likewise.
Basically need to implement the same tableview row with features similar to iOS7 mail App with 2 or 3 options on swipe left. Please find the attached image to have better idea about the request.
Attachments
This would solve a problem for me, ideally backward compatible to iOS6, but could live with iOS7 only.
That would be awesome!
This is a really cool feature. Can this feature also be added to ListView? Thanks.
We may not implement this natively in the framework, but we will at least attempt to provide a mechanism (perhaps a module) for people to do it externally.
There is no built in functionality to add "More" buttons. What the mail app does is some clever subview manipulation in a TableViewCell. This is pretty straightforward to do in TableView since you have a direct handle to the proxy and hence the view which you can manipulate. Its a little bit difficult in ListView since ListView is a data centric API which does not give you a handle to the view so animations are impossible. However it can be approximated using the right Row Animations when updating cells. Attaching a sample project which shows a proof of concept on TableView and ListView. Customize and use as required.
In iOS8 there is now a method for this functionality: "editActionsForRowAtIndexPath" Can we expect a native implementation now?
Reopening based on the ability to do this natively in iOS 8.
Any news on that?
In this feature, I am really looking forward. Can I often use in many projects.
+1
Test Case
Pull pending master - https://github.com/appcelerator/titanium_mobile/pull/6684
Is it possible to set the title of the more button? UPDATE Sorry, seen in the code now
Does this work on TableViews as well or just the ListView? Thanks, James
@James - from the pull request it seems its for a ListView only.
Release 4.1.0? Why not 3.5.2? Or 3.6.0 maybe?
[~benutzername] It is a new feature, so it will only appear in a major release, not 3.5.1. 4.0 is past feature freeze, so the next release is 4.1.0. If you like, you are welcome to pull it into a custom SDK.
maybe 4.1.0 is the next release? However I would expect a 4.0.x prior to that. Sounds like this feature is a long way to be formally implemented... however we can manually update the API ourselves in our local sdk
The Example provided by [~vduggal] is sufficient & works well.
@joseph sachs could you provide your sdk until the official release is out?
I started working on it... but then I read [~vduggal] offered a great example in Archive.zip (scroll up in description) which works nicely & "very" customizable in Ti.
Thanks
Verified fixed, using: MacOS 10.11 Studio 4.1.0.201507061821 Ti SDK 4.2.0 Appc NPM 4.1.0-1 Appc CLI 4.1.0-5 Ti CLI 4.0.1 Alloy 1.6.2 Node v0.10.37 Java 1.7.0_45 preproduction Able to create custom "more" buttons and they behave appropriately.