Skip to content
This repository has been archived by the owner on Feb 17, 2021. It is now read-only.

Add animationType to BatchUpdates #177

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

fmirault
Copy link

@fmirault fmirault commented Jan 4, 2018

and use it for insertRows / deleteRows / reloadRows / insertSections / deleteSections / reloadSections methods.

Possible addition to #124 for animations.

… / deleteRows / reloadRows / insertSections / deleteSections / reloadSections
@fmirault
Copy link
Author

Hi !

Still no news since january 4th for my PR, maybe I missed something or I have to ask for a review ?

Regards,

@@ -120,27 +120,27 @@ extension UITableView: ReloadableView {

// Update items.
if batchUpdates.insertItems.count > 0 {
insertRows(at: batchUpdates.insertItems, with: .automatic)
insertRows(at: batchUpdates.insertItems, with: batchUpdates.animationType)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we control the animations on the collection view in a similar way? See line 70 in this file.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately, in UIKit collection view doesn't have the same animation properties, you can only insert / delete / reload / move without any more possibility. :( That's why I only updated table view animations

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

More than 2 months since my last answer... Could you please at least read it ?

@staguer
Copy link
Contributor

staguer commented Apr 20, 2018

Apologies for the delay, @fmirault .

I added a comment. This adapter is used for both table views and collection views, so it'd be odd to have a property that has no effect in some cases. Would it be possible to make it (or something like it) work in both cases?

@fmirault
Copy link
Author

Collection View isn't working like Table View, so I don't really see how I can achieve the same effect on it (it's an UIKit limitation in my opinion).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants