Nadine Salter
92d6c577ed
Fix strong ASNetworkImageNodeDelegate reference.
...
Fixes #239 .
2015-01-24 11:59:41 -08:00
Nadine Salter
fab6f623a8
Deprecate -initWith{View,Layer}Class:.
...
These have been superseded by -[ASDisplayNode initWithViewBlock:] and
-[ASDisplayNode initWithLayerBlock:], respectively -- the new API allows
for custom initialisers, but does not support asynchronous display.
The old initialisers are still available in ASDisplayNodeInternal.h, for
internal subclasses and daring adventurers.
2015-01-24 11:52:27 -08:00
Nadine Salter
9f38488fd2
Bump Podfile.lock to CocoaPods 0.35.0.
2015-01-24 11:50:04 -08:00
Nadine Salter
0a5ba09136
Merge pull request #246 from facebook/ASEditableTextNode
...
ASEditableTextNode.
2015-01-23 16:05:19 -08:00
Nadine Salter
795b297c38
ASEditableTextNode.
2015-01-23 15:02:16 -08:00
Nadine Salter
1608a002e5
Merge pull request #228 from andyscott/wip/ASMultiplexImageNode-skip-failed-identifiers
...
Let ASMultiplexImageNode skip failed image identifiers
2015-01-23 12:30:47 -08:00
Nadine Salter
46f2d723f2
Merge pull request #235 from ide/bridge-node
...
ASBridgeNode: wrapper around an existing UIView with ASDisplayNode semantics
2015-01-23 12:29:50 -08:00
Nadine Salter
facfa695b8
Merge pull request #245 from andyscott/wip/fix-ASDataController-reloadSections
...
Make ASDataController call rowsInSection with the appropriate index
2015-01-23 12:28:59 -08:00
andyscott
3eba302b27
Make ASDataController call rowsInSection with the appropriate index
2015-01-23 12:03:52 -08:00
James Ide
1545384c7c
Let ASDisplayNode take a block that returns the backing view/layer
...
This adds new initializer methods to ASDisplayNode:
```objc
initWithViewBlock:(ASDisplayNodeViewBlock)viewBlock
initWithLayerBlock:(ASDisplayNodeLayerBlock)layerBlock
```
Sometimes a view can't be constructed with `-[initWithViewClass:]` but you want to use it with ASDK, so these new methods provide a way to wrap an existing view in a node.
The API is meant to preserve ASDisplayNode's behavior, so you can still construct and set properties on the node on a background queue before its view is loaded; even though the view was created a priori, it is not considered to be loaded until `node.view` is accessed.
Using the API looks like this:
dispatch_async(backgroundQueue, ^{
ASDisplayNode *node = [ASDisplayNode alloc] initWithViewBlock:^{
// Guaranteed to run on the main queue
UIButton *button = [UIButton buttonWithType:UIButtonTypeSystem];
[button sizeToFit];
node.frame = button.frame;
return button;
}];
// Use `node` as you normally would...
node.backgroundColor = [UIColor redColor];
});
The main thing this bridging API doesn't do (can't do?) is layout. Methods like `-[ASDisplayNode calculateSizeThatFits:]` and `-[ASDisplayNode layout]` cannot delegate to `[UIView sizeThatFits:]` and `[UIView layoutSubviews]` since the UIView methods must run on the main thread. If ASDK were internally asynchronous and could dispatch its layout methods to different threads (sort of like how ASTableView computes its cells' layouts) then we could mark nodes with externally provided views/layers as having "main-queue affinity" and delegate its layout to UIKit.
Test cases are included and all existing tests pass.
2015-01-22 16:31:37 -08:00
Nadine Salter
e1f8342c3b
Merge pull request #241 from facebook/add_check
...
Add check for willDeleteSections:
2015-01-22 12:38:54 -08:00
Li Tan
8ae063dec8
Add check for willDeleteSections:
2015-01-22 12:21:30 -08:00
andyscott
11e3cf518c
Slight naming adjustments for recent ASMultiplexImageNode additions
2015-01-21 22:30:24 -08:00
Nadine Salter
9a49b718f7
Merge pull request #240 from ide/range-controller-fix
...
Fix ASRangeController's delegate method invocations
2015-01-21 17:26:31 -08:00
James Ide
b5d999ab55
Fix ASRangeController's delegate method invocations
...
"did" should be "will" in a couple of places
2015-01-21 17:07:53 -08:00
Nadine Salter
74d9bb6c8f
[docs] Tweak README code snippet.
2015-01-21 14:34:09 -08:00
Nadine Salter
5558e870f6
Merge pull request #237 from facebook/table-cv-delegate-proxy
...
Default proxy object for ASTableView and ASCollectionView
2015-01-20 13:22:18 -08:00
Ryan Nystrom
afb21bf8dd
Default proxy object for ASTableView and ASCollectionView
...
fixes #231 #233
2015-01-20 13:15:39 -08:00
Nadine Salter
7542f7ca17
Fix build-break.
2015-01-20 12:16:30 -08:00
Nadine Salter
978cf85ae1
Merge pull request #211 from facebook/batch_animation
...
Batch animation
2015-01-20 11:51:31 -08:00
andyscott
60b27829e1
Let ASMultiplexImageNode skip failed image identifiers
2015-01-15 15:25:41 -08:00
Nadine Salter
63e97f0901
1.1.1.
2015-01-14 17:26:48 -08:00
Nadine Salter
718ae58177
Merge pull request #224 from facebook/warnings-as-errors
...
-Wall -Werror.
2015-01-14 16:25:43 -08:00
Nadine Salter
6d4993f414
-Wall -Werror.
2015-01-14 16:15:04 -08:00
Nadine Salter
98f389a59b
Merge pull request #223 from facebook/designated-init-call
...
Suppress build warning with designated initializer
2015-01-14 15:50:07 -08:00
Ryan Nystrom
d9a3bac05d
Suppress build warning with designated initializer
2015-01-14 15:43:28 -08:00
Nadine Salter
7e3841ec57
Merge pull request #222 from facebook/designated-init
...
ASMultiplexImageNode designated initializer
2015-01-14 15:31:02 -08:00
Ryan Nystrom
efaaa25017
ASMultiplexImageNode designated initializer
...
fixes #220
2015-01-14 15:02:15 -08:00
Ryan Nystrom
4d6b09a509
Merge pull request #221 from Jercik/master
...
Removed unintentional conversion.
2015-01-14 14:01:16 -08:00
Łukasz Jerciński
ff260f58e1
Removed unintentional conversion.
2015-01-14 22:15:41 +01:00
Nadine Salter
dd50dd63a0
Merge pull request #215 from facebook/one-placeholder
...
Actual place holding
2015-01-12 12:34:12 -08:00
Ryan Nystrom
51210d7b06
Only show a placeholder if there is a place that needs holding
2015-01-12 12:26:13 -08:00
Nadine Salter
9b8a2dcd12
Merge pull request #206 from facebook/download-images-inrange
...
Only download images when multiplex node is displayed
2015-01-09 14:47:55 -08:00
Nadine Salter
e02cae8f2e
Tidy some warnings.
2015-01-09 13:56:00 -08:00
Li Tan
90cb725b39
Fix Collection View
2015-01-08 16:27:57 -08:00
Li Tan
1068fdc413
Fix table view
2015-01-08 16:22:53 -08:00
Li Tan
00e2f46c8d
Add batch animation
2015-01-08 16:09:27 -08:00
Nadine Salter
7b37563cdc
Merge pull request #209 from facebook/mt-dispatch-once
...
Dispatch main screen scale to main once and only once
2015-01-08 14:35:09 -08:00
Ryan Nystrom
e60b51bbbf
Dispatch main screen scale to main once and only once
...
fixes #183
2015-01-08 14:24:34 -08:00
Nadine Salter
3e851e253a
Merge pull request #208 from facebook/add_flowlayout_safety_check
...
Add safety check to avoid crash in ASFlowLayoutController
2015-01-08 11:53:26 -08:00
Li Tan
123cab757a
Add safety check to avoid crash in ASFlowLayoutController
2015-01-08 11:49:31 -08:00
Ryan Nystrom
ae1349eb16
Start downloading images when multiplex node is displayed
...
fixes #178
2015-01-07 17:18:00 -08:00
Nadine Salter
42f801f269
Merge pull request #205 from facebook/image-load-blocking
...
Dispatch lazy image downloaders to another thread
2015-01-07 16:36:19 -08:00
Ryan Nystrom
ebe614b8c9
Dispatch lazy image downloaders to another thread
...
fixes #148
2015-01-07 16:22:39 -08:00
Nadine Salter
bacfcbd24d
Merge pull request #202 from facebook/batch_insertion
...
Batch insertion for reload #200
2015-01-07 14:53:15 -08:00
Nadine Salter
55f4888cc3
Merge pull request #203 from facebook/fix_flow_controller
...
Fix crash in Flow Controller
2015-01-06 20:26:43 -08:00
Li Tan
b9c6f3de03
Fix crash in Flow Controller
2015-01-06 18:04:42 -08:00
Li Tan
a8dbec9dfa
fix
2015-01-06 17:45:48 -08:00
Li Tan
3adb0b1b93
Batch insertion for reload
2015-01-06 17:43:16 -08:00
Nadine Salter
c4b3efffc9
Merge pull request #201 from facebook/touch-forwarding
...
Forward touch events to either the node or super
2015-01-06 16:10:02 -08:00