* Expose textLayoutForConstraint:
- Expose textLayoutForConstraint:, but make unavailable on ASTextNode
- Refactor compatibleLayoutWithContainer:text: into a static method
* Instead of textLayoutForConstraint: expose shouldTruncateForConstrainedSize: in ASTextNode
* ASTextNode2 rendering corrections.
ASTextNode2 was only setting truncationMode (lineBreakMode) on existing paragraph styles in attributedString (thus having no effect for the two non-truncating modes if there were not any existing paragraph style runs).
ASTextLayout (essentially YYTextLayout) was not rendering the two non-tail truncation lineBreakModes correctly. There's not much history on github but it appears to me that it was set up correctly at one time and then some additional code was added for unclear reasons that assumed any truncation was at the end of the string.
This commit corrects both issues.
* Update CHANGELOG.md
* fix SIMULATE_WEB_RESPONSE not imported #449
* Fix to make rangeMode update in right time
* remove uncessary assert
* Fix collection cell editing bug for iOS 9 & 10
* Revert "Fix collection cell editing bug for iOS 9 & 10"
This reverts commit 06e18a10596622ff8a68835c95a23986d7bf61ea.
* fix mismatch of name array and experimental features
* add more tests
* remove nslog
* add change log
* fix tests
ASTextNode2 uses ASTextLayout to calculate its layout and bounding rect. When the constrained width that is used for layout calculation is inf/max (e.g when the node is inside a horizontal stack), ASTextLayout doesn't ignore its right/center/natural text alignment but takes it into account. That results in an unreasonable size (and position).
Fix by detecting when the node is calculating intrinsic size and force its layout alignment to be left. Other alignments should still work when the max width is finite/reasonable.
* fix SIMULATE_WEB_RESPONSE not imported #449
* Fix to make rangeMode update in right time
* remove uncessary assert
* Fix collection cell editing bug for iOS 9 & 10
* Revert "Fix collection cell editing bug for iOS 9 & 10"
This reverts commit 06e18a10596622ff8a68835c95a23986d7bf61ea.
* Only test when photo library is enabled.
It will fail to build if photo library is disabled cause the test is
depending on it.
* Add ChangeLog.
* set default tuning parameters for collection/table node
* add change log
* Move to framework private.
* Apply to tableNode
* trigger ci
* fix directory
* fix file link
This is a follow up on #1136. Our experiment results show that clearing data frequently is the cause of our #1 crash. @maicki and I believe that this is because if the collection view is being used, silently clearing its data without notifying the backing UICollectionView can put it out-of-sync and causes mayhem next time the collection view processes a batch update. If you look at the stack trace closely, you'll notice that the crash doesn't occur on the same run loop that clearData is called. This made it extremely tricky to investigate and identify the root cause.
Another interesting question would be whether or not we want to clear the data during deallocation at all, since the data will be cleared out soon anyway.
* Simpler Huy fix for more efficient delayed flattening of the layout tree
* Nit
* Remove pbx changes
* Update CHANGELOG.md
* Add note about change in timing of _flattenedLayout capture
* Apply recommended warnings
* Squelch designated initializer warning in ASViewController
* Remove unused compiler flag
clang: warning: argument unused during compilation: '-fno-objc-arc-exceptions' [-Wunused-command-line-argument]
* Fix warning about overriding an instance variable within a category
Instance method 'methodOverrides' in category from _ASDisplayView.o overrides method from class in ASDisplayNode.o
* add a method for setting preconfigured PINRemoteImageManager instead of using the self-created ASPINRemoteImageManager
* update preconfigured image manager where it can only be set once
* fix spacing in downloader
* Fix doc/comments on new api
* adding assertion to ensure either only configuration or preconfigure image manager can be set at a time
* adding assertion to ensure either only configuration or preconfigure image manager can be set at a time
* fix assertion condition
* Update CHANGELOG.md
* Remove unnecessary change
* Remove use of NSHashTable for interface state delegates #trivial
* Stray line
* One more case
* Add code to let people have more delegates
* Do it more
- Fix typos in ASEditableTextNode.h and ASDisplayNode+FrameworkPrivate.h.
- Remove unnecessary declaration for ASPINRemoteImageDownloader's sharedDownloader class property.
- Remove unnecessary empty lines in ASPINRemoteImageDownloader.m and ASEditableTextNode.h.
* fix SIMULATE_WEB_RESPONSE not imported #449
* Fix to make rangeMode update in right time
* remove uncessary assert
* Fix collection cell editing bug for iOS 9 & 10
* Revert "Fix collection cell editing bug for iOS 9 & 10"
This reverts commit 06e18a10596622ff8a68835c95a23986d7bf61ea.
* Fix interface state not update correctly during layer thrash
* add change log
* fix SIMULATE_WEB_RESPONSE not imported #449
* Fix to make rangeMode update in right time
* remove uncessary assert
* Fix collection cell editing bug for iOS 9 & 10
* Do not cancel on exit, interface state update should handle it.
* Revert "Fix collection cell editing bug for iOS 9 & 10"
This reverts commit 06e18a10596622ff8a68835c95a23986d7bf61ea.
* add space to trigger ci
* add change log
* fix SIMULATE_WEB_RESPONSE not imported #449
* Fix to make rangeMode update in right time
* remove uncessary assert
* Fix collection cell editing bug for iOS 9 & 10
* Rename to reordering.
* Adjust _reordering more acuratedly
* Add change log
* fix SIMULATE_WEB_RESPONSE not imported #449
* Fix to make rangeMode update in right time
* remove uncessary assert
* Allow to add interface state delegate in background threads.
* Allow to add interface state delegate in background threads.
* lock around _interfaceStateDelegates
* lock _interfaceStateDelegates to local variable
* Fix comments
* remove extra spaces