Commit Graph
241 Commits
Author SHA1 Message Date
Rahul Malik f388180a1d Refactor the run loop implementation code into a proper queue abstraction.
ASRunLoopQueue can process a specified number of items per run loop iteration
via a block based api.
2016-03-07 23:49:50 -08:00
Rahul Malik 5af8b78d78 Transfer node ownership from renderQueue to displayingNodes queue before removing
the node from the renderQueue.
2016-03-07 11:30:23 -08:00
Rahul Malik 62a39c49ea Break up scheduling of node rendering across various run loops 2016-03-06 12:33:31 -08:00
Huy Nguyen caddd1d287 Fix threadSafeBounds
- Bounds change set directly to _ASDisplayLayer should also be saved to threadSafeBounds
- Remove overkill _usesDisplayView flag
2016-03-03 16:18:07 -08:00
Huy Nguyen 3b0b7fa888 More locks 2016-03-03 15:05:17 -08:00
Levi McCallum 4601cd5d1e Preserve usesImplicitHierarchyManagement when doing animations
Currently the flag was being reset to NO in all cases. It should ignore turning off the hierarchy management when the user has already enabled it.
2016-03-03 08:40:08 -08:00
Huy Nguyen b21974e3f4 Address Scott's comment 2016-03-03 00:33:19 -08:00
Huy Nguyen f59eb98749 Remove threading assumption in ASDisplayNode measureWithSizeRange:" 2016-03-03 00:31:05 -08:00
Huy Nguyen 5e49cc4382 Layout transition can measure in background 2016-03-02 22:47:04 -08:00
Huy Nguyen 9162d7b2df Implement thread-safe bounds and use it in ASTextNode 2016-03-02 22:42:53 -08:00
appleguy 8f0777e7e5 Merge pull request #1305 from garrettmoon/fixRecursivelyEnsureDisplay
[ASDisplayNode] recursivelyEnsureDisplay should trigger display even if a stale contents exists (re-display)
2016-03-01 17:43:28 -08:00
Garrett Moon 2cee9bfca8 Just because we have contents, doesn't mean we don't want to display 2016-03-01 17:41:29 -08:00
Garrett Moon 057c431dfb Thanks @scottg, this is a better more generalized solution. 2016-03-01 16:46:03 -08:00
Garrett Moon eba6afc36b Revert "Don't clear contents when moving between nodes"
This reverts commit 6d1732fcbd.
2016-03-01 16:45:36 -08:00
Garrett Moon 6d1732fcbd Don't clear contents when moving between nodes 2016-03-01 09:57:07 -08:00
Huy Nguyen 640b6bdf4a Fix mismatch between the signature of didCompleteLayoutTransition and its implementation 2016-02-25 10:58:36 -08:00
appleguy 3abde9348d Merge pull request #1256 from Adlai-Holler/AHAffinityRevisions
[ASDisplayNode] Post-Review Refinements of Recent No-Affinity UIKit/CA Property Bridging
2016-02-22 20:41:59 -08:00
Adlai Holler 767bff2e1a [ASInternalHelpers] Use ASDisplayNodeThreadIsMain, reduce block allocations 2016-02-22 15:12:13 -08:00
Adlai Holler f4e4c501f1 [ASDisplayNode] Remove misplaced comment that has been replaced 2016-02-22 09:06:36 -08:00
Adlai Holler deccef1d94 [ASDisplayNode] Lock during constrainedSizeForCalculatedLayout 2016-02-22 09:04:01 -08:00
Adlai Holler 648dc817ad [ASDisplayNode] Use a C function to lazily create pending view state 2016-02-21 10:03:06 -08:00
Adlai Holler edf6ee59e8 [ASDisplayNode] Remove RespectThreadAffinityOfNode function 2016-02-20 15:43:00 -08:00
Adlai Holler d9fc11f0f2 [ASDisplayNode] Remove thread affinity assertion in -shouldRasterizeDescendants 2016-02-20 15:43:00 -08:00
Adlai Holler e9712cdfa1 Make the tests sturdier, improve setNeedsLayout/setNeedsDisplay bridging 2016-02-20 15:43:00 -08:00
Adlai Holler 636c8c04f3 Improve bridging of frame property 2016-02-20 15:43:00 -08:00
Adlai Holler 563d0893a3 Beef up the properties, beef up the demo app 2016-02-20 15:43:00 -08:00
Adlai Holler a46bd8e29b More tests, all but 1 passing 2016-02-20 15:40:47 -08:00
Adlai Holler c9d53517fa Lock node's properties while pending view state is applied 2016-02-20 15:40:47 -08:00
Adlai Holler b5b5f9f559 Some clean up 2016-02-20 15:40:47 -08:00
Adlai Holler 99b674c346 Lay some foundation for our new pending state controller 2016-02-20 15:40:47 -08:00
Scott Goodson d899f12f70 [ASCellNode] Layout delegate should not be public as it must not be reset externally.
Do not call layout delegate method before the cell node is loaded.  This can happen if
application code calls -setNeedsLayout on the cell manually, and can confuse UIKit state
because we submit an empty batch update call on the next runloop.
2016-02-20 15:24:44 -08:00
appleguy a4789f3524 Merge pull request #1231 from garrettmoon/reducePlaceholderFadeCost
[Placeholders] Only start a fading animation if we're visible. And a threadsafety fix.
2016-02-16 15:20:24 -08:00
Garrett Moon 74661e27f6 Only start a fading animation if we're visible. And a threadsafety fix. 2016-02-16 13:42:56 -08:00
Scott Goodson fce722b0c8 [ASDisplayNode] Allow display-scheduling method to be called concurrently. 2016-02-13 00:58:56 -08:00
Levi McCallum b267821d4c Wrap implicit node hierarchy management behind feature flag property 2016-02-10 19:21:29 -08:00
Levi McCallum 163ddb1240 Layout only immediate subnodes of a node 2016-02-10 15:13:46 -08:00
Levi McCallum 6f37bb40d9 Allow layouts to be accessible in context 2016-02-10 14:39:46 -08:00
Levi McCallum 870cc405e6 Remove removedSubnodes instead of insertedSubnodes 2016-02-10 11:44:13 -08:00
Levi McCallum 50a41df7b0 Return current layout if pending layout isn't needed 2016-02-10 11:44:13 -08:00
Levi McCallum 499c3331ce Optimize insertion/deletion node calculation & expose inserted/deleted subnodes to transition context 2016-02-10 11:44:13 -08:00
Levi McCallum d669cadcba Use core layoutSublayouts method for layout step 2016-02-10 11:44:13 -08:00
Levi McCallum e57761ffbe Fix pending layout reference causing nil references 2016-02-10 11:44:13 -08:00
Levi McCallum a00e9bb41c Clean up node transition API 2016-02-10 11:44:12 -08:00
Levi McCallum 8737e242f8 Extract measurement and transition into different methods based on feedback 2016-02-10 11:44:12 -08:00
Levi McCallum 5cf5cb8452 Delegate layout frame calculation to sublayout method 2016-02-10 11:44:12 -08:00
Levi McCallum 1513ee8ca5 Expose the layout's immediate sublayouts as the accessing nodes 2016-02-10 11:44:11 -08:00
Levi McCallum d8d76635ff Perform animation transition on measureWithSizeRange instead of separate method 2016-02-10 11:44:11 -08:00
Levi McCallum 8238da8d00 Fix node deletion and flatten identification issues 2016-02-10 11:44:11 -08:00
Levi McCallum 043012718b Remove debug log 2016-02-10 11:44:11 -08:00
Levi McCallum 51977ed162 Identify flattened layouts to allow filtering of non-hierarchy nodes 2016-02-10 11:44:11 -08:00