New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow drop on empty part of table #15
Comments
Looks good. Please create a PR to the Before you PR, could you run through the Test App scenarios just to double check that it doesn't cause any issues? Thanks! |
Will do. I'll have to follow up on this over the next several days but I will run the tests. |
Made significant progress on this tonight. More to do than I thought but should have it solid for all Test app scenarios soon. |
See issues with #18 |
Hi Steve and Craig, I'm currently using this library in one of my apps and looking forward to having this functionality. Is there anything I could assist with to help implement this? |
Hi @prbsparx, check out Craig's PR. If you want to move this issue along, it would be very helpful if you could review and try to resolve the issues that I've highlighted in the comments. I'd me happy to merge it into the next release if we can make it more stable. :) |
Proposing the following algorithm for coordination on drag stop, which should resolve this and #34:
|
… methods. Also added note about #36
We need to change the render delegate protocol as well to offer methods for rendering both appendation and exchanging. |
… Build failing due to BC breakage of the data source protocol
…ds for appending and exchanging
…te tests and seems as though all of the refactored coordinator tests pass again - going to backwards test them now
… if we drop on a valid droppable collection
… the delete drag data source methods to be more expressive of the fact that deletion can occur at any point in the arena
…xchange / append methods and used a shared behaviour to test both new methods
… as exchanging. @cvconover Looks like we finally have this in place for v2.
I thought it was not as intuitive to force the user to drop the first item at the very top on an empty table, so I made some mods that I think could improve the UX but I am not certain if there are any negative repercussions as I have not done extensive testing, yet, but so far it looks good. Here's what I did.
In I3DragBetweenHelper, I commented out lines 792 - 797 (if nil check on drop index)
https://github.com/ice3-software/i3-dragndrop/blob/master/Classes/I3DragBetweenHelper.m#L792
Then in the delegate method, droppedOnDstAtIndexPath:to fromSrcIndexPath:from, I check for index==nil and just create a new NSIndexPath with row set to the size of the datasource of the target table. I have to do the same in the srcTable as I did in the dstTable, obviously.
Hope this can make it into your sources as feature if you see it as useful.
The text was updated successfully, but these errors were encountered: