11 Commits

Author SHA1 Message Date
Huy Nguyen
8c45eaefce [Batch Fetching] Add ASBatchFetchingDelegate (#281)
* Add ASBatchFetchingDelegate
- In addition to checking remaining leading screens, ASBatchFetching now also calculates a remaining time and consults its delegate if needed.
- The delegate can override the decision of ASBatchFetching, for example based on remaining time and average time of past batch requests.

* Fix up tests

* Update CHANGELOG
2017-05-17 13:26:30 +01:00
Adlai Holler
588f30c7dd Move Last Few Properties from ASTableView,ASCollectionView to Node (#225)
* Finish moving properties ASTableView->ASTableNode, ASCollectionView->ASCollectionNode

* Update changeling
2017-05-04 13:41:58 +01:00
Adlai Holler
a7656766f9 Make Cell Node Properties Atomic (#74)
* Make ASCellNode indexPath and supplementaryElementKind atomic

* Update the change log

* Fix licenses

* Be explicit with atomic

* Rename the protocol

* And the file
2017-05-02 14:09:12 -07:00
Garrett Moon
8013e25524 Update license v2 (#67)
* Fixed license

* Update all licenses

* Update Dangerfile for new license

* Update already updated licenses

* Closer…

* Closer…

* Closer…

* Closer…

* Closer…

* Closer…

* Closer…

* Closer…

* Closer…

* Closer…

* Closer…
2017-04-24 16:59:57 -07:00
Huy Nguyen
dcf858eac1 [ASDisplayNode] Trigger a layout pass whenever a node enters preload state (#3263)
* Add a thread-safe layoutIfNeeded implementation to ASDisplayNode

* Trigger a layout pass when a display node enters preload state
- This ensures that all the subnodes have the correct size to preload their content.

* ASCollectionNode to trigger its initial data load when it enters preload state

* Minor change in _ASCollectionViewCell

* Layout sublayouts before dispatch to main for subclass hooks

* Update comments

* Don't wait until updates are committed when the collection node enters display state

* Same deal for table node

* Explain the layout trigger in ASDisplayNode
2017-04-13 16:25:17 -07:00
Huy Nguyen
c642771e1c Remove unused initializer in ASTableNode (#3268) 2017-04-13 16:11:32 -07:00
Huy Nguyen
3d19923731 [Trait collection] Correctly handle changes that occur mid-updates (#3224)
* Add unit test to test trait collection changes occur during updates are handles correctly

* Remove handling code in ASDataController:updateWithChangeSet. Previous test should fail

* Correctly handle trait collection changes that occur mid-updates
- Currently, when there is a new trait collection, we correctly propagate it to all visible elements. However, since the propagating block is executed on main thread immediately without waiting for the background editing queue of ASDataController, not all elements are updated.
- Then to fix that, we updated ASDataController to handle these changes inside updateWithChangeSet. This works, but it doesn’t address the underlying issue.
- We now delegate the propagating task to ASDataController which schedule a block to its main serial queue after waiting for its background editing queue.
2017-03-31 10:47:59 -07:00
Adlai Holler
fcbbea51a6 Fix the Initialization Hierarchy (#3207)
* Fix the initializers setup

* Update Swift example

* Remove incorrect comment

* Add one to ASTableNode
2017-03-28 11:48:20 -07:00
Huy Nguyen
bf41847665 Don't load collection/table node just to wait for updates to be committed (#3182)
- Because there would be no update otherwise.
2017-03-15 08:55:50 -07:00
Adlai Holler
bccfc6c779 Don't Load Table/Collection Node Just Because User Updated (#3120)
* Allow user to update collection/table without forcing view to load

* Capture animation enabledness
2017-03-02 10:11:30 -08:00
Adlai Holler
73ca6ab514 Shuffle & Cleanup Stuff (#3080) 2017-02-26 18:14:13 -08:00