107 Commits

Author SHA1 Message Date
appleguy
dc0d22dff4 Merge pull request #647 from rcancro/stackBaseLine
Removed ASBaselineLayoutSpec and made baseline alignment part of ASStackLayoutSpec
2015-09-10 18:16:37 -07:00
rcancro
4bb8472182 Removed ASBaselineLayoutSpec and made baseline alignment part of ASStackView 2015-09-10 17:29:39 -07:00
rcancro
b85316d8bc a couple comment updates 2015-09-10 13:19:13 -07:00
rcancro
23497379e4 added comment to give guidance if a user is getting crashing in finalLayoutable 2015-09-09 11:51:36 -07:00
rcancro
2a030c9841 First thoughts on fixing the finalLayoutable method. 2015-09-09 09:13:02 -07:00
rcancro
fe4a2d272f add locks to ASLayoutOptions 2015-09-08 09:50:47 -07:00
rcancro
b3369ca388 making ASLayoutOptions threadsafe 2015-09-08 09:50:47 -07:00
rcancro
fca43a651f Make layoutOptions readonly 2015-09-08 09:50:47 -07:00
rcancro
5786bc1b5b Fixed infinite recursion in finalLayoutable, removed child properties from ASLayoutSpecs 2015-09-08 09:50:47 -07:00
rcancro
84cd80c41d bug in setting the ASLayoutOptions default class. 2015-09-08 09:50:47 -07:00
rcancro
36d00273fb wasn't copying layout options to final layoutable. 2015-09-08 09:50:47 -07:00
rcancro
8263a9f53a Kittens sample working 2015-09-08 09:50:47 -07:00
rcancro
cbaf178950 Hide ASLayoutOptions from the user 2015-09-08 09:50:47 -07:00
rcancro
15b3fd6eab Moved ASLayoutable* properties into ASLayoutOptions class 2015-09-08 09:50:27 -07:00
rcancro
7446578f6f Added method to ASLayoutable to allow a layoutable to override how it will be added to the layoutSpec.
Also moved ASStaticLayoutSpec to act more like the other layouts.
2015-09-08 09:49:40 -07:00
Garrett Moon
62303ebeec array must be init'd otherwise arrayByAddingObject returns nil. 2015-08-28 13:37:39 -07:00
rcancro
9bf62d14ab Merge remote-tracking branch 'upstream/master' into baseline
# Conflicts:
#	AsyncDisplayKit/Layout/ASLayoutSpec.h
#	AsyncDisplayKit/Layout/ASStackLayoutSpec.mm
2015-08-24 09:54:36 -07:00
appleguy
38eae3ab77 Merge pull request #623 from rcancro/layoutSpec
ASLayoutSpec are temporarily mutable and have a more obj-c interface
2015-08-23 11:31:07 -07:00
rcancro
1d31a21ccb Merge branch 'baseline' of github.com:rcancro/AsyncDisplayKit into baseline
# Conflicts:
#	AsyncDisplayKit.xcodeproj/project.pbxproj
#	AsyncDisplayKit/ASTextNode.h
#	AsyncDisplayKit/Details/ASDataController.mm
2015-08-22 19:14:59 -07:00
rcancro
e991242513 removed "Stack" from baseline related layout names 2015-08-22 19:03:55 -07:00
rcancro
49ac178166 huy's comments 2015-08-22 19:03:55 -07:00
rcancro
1424127813 fixed copyright 2015-08-22 19:03:54 -07:00
ricky cancro
5d286930f6 Renamed ASStackText... to ASBaselineStack... 2015-08-22 19:03:54 -07:00
ricky cancro
2d6ddfe32e moved baseline alignment to a layout spec. 2015-08-22 19:03:54 -07:00
rcancro
9036ab8e7d new stack layout spec for text 2015-08-22 19:03:54 -07:00
ricky cancro
ef89f758bc flailing 2015-08-22 19:03:54 -07:00
ricky cancro
3fd241e87e fixed vertical spacing bug and typo 2015-08-22 19:03:54 -07:00
ricky cancro
cf428831a4 Added baseline spacing for vertical stack views. 2015-08-22 19:03:54 -07:00
ricky cancro
f289b3345a Add baseline support to ASStackLayoutSpec 2015-08-22 19:03:54 -07:00
rcancro
0ea276e3ab huy's comments 2015-08-22 18:47:16 -07:00
rcancro
680305704a addressed comments and fixed tests 2015-08-21 21:03:40 -07:00
rcancro
c06a6be188 ASLayoutSpec are temporarily mutable and have a more obj-c interface 2015-08-21 16:02:36 -07:00
rcancro
608f62d487 fixed copyright 2015-08-21 10:08:15 -07:00
ricky cancro
023ad89815 Renamed ASStackText... to ASBaselineStack... 2015-08-21 08:54:28 -07:00
Garrett Moon
6624b84c4c Static layout doesn't properly set a height for collection view cells
because their size.width / size.height isn't nan, but FLT_MAX.
2015-08-20 10:40:00 -07:00
ricky cancro
f404231b35 moved baseline alignment to a layout spec. 2015-08-20 10:38:54 -07:00
rcancro
e7ffe67e3c new stack layout spec for text 2015-08-19 22:03:02 -07:00
ricky cancro
774d91653b flailing 2015-08-19 16:59:23 -07:00
ricky cancro
11896904a2 fixed vertical spacing bug and typo 2015-08-15 09:45:14 -07:00
ricky cancro
d7564e18e5 Added baseline spacing for vertical stack views. 2015-08-15 08:17:43 -07:00
ricky cancro
afffd9cfb2 Add baseline support to ASStackLayoutSpec 2015-08-12 16:55:12 -07:00
Huy Nguyen
3992e9b09b [appledoc] Fix all remaining warnings. 2015-07-12 17:27:44 +07:00
Huy Nguyen
e1fd58268c Clean up #468:
- -layoutSpecThatFits: must return an ASLayoutSpec.
- Move ASDisplayNode's -measureWithSizeRange: redeclaration to ASDisplayNode.h.
- Rename ASStackLayoutChild.h to ASStackLayoutDefines.h.
- Rename ASStaticLayoutSpecDimension.h to ASRelativeSize.h.
- Don't import ASLayout.h in other headers to prevent circular inclusions.
- Explain use cases of ASLayout's initializers.
- Clean up ASInternalHelpers.h.
2015-07-10 19:41:17 +07:00
Ryan Fitzgerald
83ac5ad823 changing layoutableObject to be a weak reference to avoid retain cycle between ASDisplayNode and its Layout 2015-07-08 09:58:31 -04:00
Huy Nguyen
51f1ed819f - ASDisplayNode now caches calculated layout requested by layout specs.
- constrainedSizeForCalculatedLayout is of type ASSizeRange.
- calculatedLayout is better explained.
- Since ASLayout is cached and reused, its position property is mutable.
2015-07-06 22:08:01 +07:00
Huy Nguyen
2a3753516a Fix naming convention: Rename ASLayout's "children" to "sublayouts". 2015-07-01 18:13:54 +07:00
Huy Nguyen
2149d44990 Fix naming convetion:
- "Layout node" is changed to "layout spec".
- Update tests.
- Update Kittens sample.
2015-07-01 18:13:44 +07:00
Huy Nguyen
eb5670032d ASDisplayNode flattens the ASLayout calculated from its layout spec and stores the result. This reduces memory footprint and gives -layout a performance gain. 2015-06-30 20:18:11 +07:00
Huy Nguyen
4799a9d206 Remove ASLayoutChild. ASLayout now has a position property defaults to (NAN, NAN). 2015-06-30 19:42:38 +07:00
Huy Nguyen
95e787b226 Remove stack children type:
- ASLayoutable requires mutable properties that are used when attached to a stack layout.
- Thus, ASLayoutable objects (including ASDisplayNode) can be injected into stack layout directly.
- ASStackLayoutNodeChild no longer needed.
- Tests and Kitten sample updated.
2015-06-26 11:47:42 +07:00