Commit Graph
4960 Commits
Author SHA1 Message Date
Michael Schneider c2806aaf9b Removed category overwrite 2019-06-13 07:41:13 -07:00
Michael Schneider d1f268932a Address comments and improvements 2019-06-13 07:41:13 -07:00
Michael Schneider bf34436aff Add handling in ASButtonNode back for non flag 2019-06-13 07:41:13 -07:00
Michael Schneider 6439dfb922 Add support for accessibility handling of ASTextNode2 attributed text links 2019-06-13 07:41:13 -07:00
Garrett Moon 2de8eec67e Upgrade Xcode and Cocoapods (#1552)
* Upgrade Xcode

* Update examples for new cocoapods / swift

* Fix carthage mode in build.sh
2019-06-12 18:41:54 -07:00
Garrett Moon ef06cfe843 Update how to contribute docs (#1553) 2019-06-12 16:29:32 -07:00
Huy Nguyen 9b8120656b [Dev docs] How to develop with Texture (#1538) 2019-06-11 16:59:10 -07:00
Michael Schneider 172614855a Adjust how AS_ENABLE_TEXT_NODE is used to fix Xcode cmd+click & editor support. (#1546) 2019-06-10 15:17:37 -07:00
Michael Zuccarino a6a03c638b [Dev docs] Debugging documentation (#1328)
* Starting doc skeleton and debugging UIKit crash document

* Iterate Debugging docs

* Scope to only debug, include Weaver

* Typos
2019-06-10 10:40:54 -07:00
Wu Zhong 1cb2334cf0 NetworkingImageNode: update URL if we found image in assets (#1473) 2019-06-07 16:00:25 -07:00
Adlai Holler 731db8c9ee In text measurement, don't eagerly create arrays for attachments since we don't usually have attachments. (#1535)
PRESUBMIT=passed
R=mcudich,wiseoldduck
CC=maxwang,yt-elements-eng+cl
APPROVED=mcudich
REQUIRED_REVIEW=1
DELTA=25 (11 added, 8 deleted, 6 changed)
DELTA_BY_EXTENSION=mm=17
OCL=242501658
NO_SQ=Test failures are unrelated.


P4 change: 242514626
2019-06-06 07:50:19 -07:00
Michael Schneider 19fb1240ad Fix multiple issues around accessibility handlinig (#1537)
* Improve Accessibility Implementation

- Fixes calculations for accessibilityFrame of ASAccessibilityCustomAction and ASAccessibilityElement
- Fix crash for accessibility elements within layer backed nodes
- Fix accessibility action label updating after other actions change the accessibility label of the corresponding node

* Address comments
2019-06-05 13:51:25 -07:00
Michael Schneider ab8ea069ea Add support for basic ASTextNode2 link highlighting (#1518)
* Add support for basic ASTextNode2 link highlighting

* Add approach to fix line highlighting

* Enable proper highlighting for first row

* Fix snapshot highlighting test for ASTextNode2

* Update screenshot again

* Address comments
2019-06-03 08:57:31 -07:00
Adam Bell 1b4b6a3f02 Fix Opting-Out of Linking with Photos Framework (#1519) 2019-06-03 08:56:48 -07:00
Garrett Moon a3f25d05f9 Remove the text rendering experiment. (#1531)
* Remove the text rendering experiment. It decreased rendering speeds at a negligible improvement to OOMs.

* Adopt new ASGraphicsCreateImageWithOptions API
2019-06-03 08:56:31 -07:00
Michael Schneider 62e5a8e86c Use flag for responder chain methods between view and node dispatching (#1522)
* Use flag for responder chain methods between view and node dispatching

* Use bitfields
2019-05-30 07:18:07 -07:00
Michael Schneider a2abd00276 Fixes UIKit version of ASDKGram (#1521)
* Several fixes for UIKit version of ASDKGram

* Remove PhotoCollectionViewCell
2019-05-29 10:32:21 -07:00
Michael Schneider 08d5e81e3b Remove ASExperimentalDisableAccessibilityCache (#1515)
* Remove ASExperimentalDisableAccessibilityCache

* Some more removal
2019-05-29 09:38:01 -07:00
Michael Schneider 8f69334b4c Assign accessibilityElements to _accessibilityElements (#1516) 2019-05-24 11:16:48 -07:00
Michael Schneider b621c63241 Small cleanup to remove unnecessary internal import (#1517) 2019-05-23 10:07:50 -07:00
Huy Nguyen e1859a1029 Ship ASExperimentalImageDownloaderPriority (#1480) 2019-05-21 22:23:24 -07:00
Adlai Holler 0a3a37e8ca Reclaim pending display nodes memory once the subtree is finished drawing (#1509) 2019-05-10 16:31:54 -07:00
Adlai Holler 27fe219d14 Reclaim CALayer asyncTransactions set, use NSMutableSet instead of heavy/slow NSHashTable (#1510) 2019-05-10 16:31:24 -07:00
Greg Bolsinga 7fb427e0f3 Shrink LayoutSpec classes (#1502)
- Resize enums to make `ASStackLayoutSpec` 40 bytes smaller. This applies to the subclasses too.
2019-05-09 20:19:07 -07:00
Kevin 409bc4811c Cleanup whitespace #trivial (#1507)
(It's easier to deal with these as silly oneoffs IMO than to
have them conflated with real work)
2019-05-09 16:01:52 -07:00
Greg Bolsinga e35db6bb0f Shrink ASLayout (#1503)
- Shrink the enum. Save 8 bytes. There are 1000s of these in the heap after running Pinterest for 10 minutes.
2019-05-09 07:49:07 -07:00
Adlai Holler 4cd8e82996 ASSignpost: Add support for the os_signpost API, fixes (#1501)
* ASSignpost: Add support for the os_signpost API

- Removes support for colored intervals. These weren't really useful and they aren't part of the signpost api.
- Fixes an issue with range controller interval logging.
- Adds an interval for interface orientation changes.

* Rename

* Support Xcode 9

* Commentary
sync-base-05-09-19
2019-05-08 19:59:13 -07:00
Greg Bolsinga 6e1600571c Shrink ASEditableTextNode by 16 bytes (#1500)
Just shuffle some BOOLs around and explicitly declare an ivar so it is grouped with the others.
2019-05-07 21:02:03 -07:00
Greg Bolsinga 83389d92e2 Shrink ASCellNode by 8 bytes (#1499)
Group the BOOLs together, since there are only 4 (and there are no other auto-generated ivars that are < 64 bits) this is sufficient and keeps the properties `atomic`.
2019-05-07 20:14:40 -07:00
Greg Bolsinga 87335d8dc5 Keep the atomics - does not affect memory work (#1498)
Revert "Ensure ASControlMode properties lock before accessing their ivars (#1476)"
This reverts commit ce1e1956f4.

Revert "Make sure all ASDisplayNode properties have backing ivars for consistency. (#1475)"
This reverts commit d6061f4390.
- Except the unused property `interfaceStateSuspended` is still removed (this is a memory saver).
2019-05-07 20:14:19 -07:00
Greg Bolsinga 7470052f55 Remove unused declaration, missed in #1460 (#1497) 2019-05-07 13:42:22 -07:00
Greg Bolsinga 4d1176be4d Shrink ASImageNode by .6% and ASNetworkImageNode by 2.2% (#1487)
* Shrink ASImageNode by .6% and ASNetworkImageNode by 2.2%

ASImageNode goes from 1384 to 1376. ASNetworkImageNode goes from 1496 to 1464.

These objects accumulate in the heap, so reducing their size will allow more to accumulate before memory warnings.

Group the `BOOL`s into a struct. Shrink the various stored `enum`s to fit the size of their contents. Move the ivars around so that the smaller `enum` are near eachother and the bitfield struct.

* add comments as requested in garrett's review.

* access ivar directly since already locked as suggested in review.
2019-05-07 11:17:59 -07:00
Greg Bolsinga 8b70b760db Shrink Pager and Scroll Node (#1496)
Running on iPhone SE Simulator:
ASPagerNode 1240 to 1232 bytes .7% reduction
ASScrollNode 1104 to 1096 bytes .7% reduction

- make ASScrollNode smaller by shrinking ASScrollDirection, which requires a change to ASRangeController
- shrink ASPagerNode by declaring the BOOL next to the struct
2019-05-07 09:58:11 -07:00
Greg Bolsinga 3374706e67 Shrink TextNode(2) (#1495)
Running in iPhone SE Simulator:
- ASTextNode: 1360 to 1352 bytes .6% reduction
- ASTextNode2: 1360 to 1304 bytes 4.3% redction

Shrink stored enum sizes. Group BOOLs near these smaller enums. Override -usingExperiment to return constant instead of never set, but allocated ivar.
2019-05-07 09:57:49 -07:00
Greg Bolsinga 2fdcee81cd Shrink Button Node (#1494)
Button: 1312 to 1288 bytes, running on iPhone SE simulator. 1.9% reduction.

Shrink the enums it stores, and place them next to each other (along with a BOOL) to reduce instance size.
2019-05-07 09:57:03 -07:00
Greg Bolsinga c571c8d1c4 Shrink ASDisplayNode from 1072 to 968 bytes, reduction of 10.74% (#1484)
* Shrink ASDisplayNode from 1088 to 976 bytes, reduction of 11.48%

These objects accumulate in the heap, so reducing their size will allow more to accumulate before memory warnings.

Group the `BOOL`s into a struct. Shrink the various stored `enum`s to fit the size of their contents. Move the ivars around so that the smaller `enum` are near eachother and the bitfield struct.

* Forgot to bit-field-ify placeholderEnable; new small size is 968, old size is 1072 (measured consistentlyl on iPhoneSE simulator). 10.74% reduction.
2019-05-07 09:56:33 -07:00
Greg Bolsinga b9e0fddc04 Shrink _ASPendingState from 824 to 808 bytes, reduction of ~2% (#1483)
* Shrink _ASPendingState from 824 to 808 bytes, reduction of ~2%

These objects accumulate in the heap, so reducing their size will allow more to accumulate before memory warnings.

Shrink ASPendingState BOOLs. Use unsigned int for these bitfields for clarity. Separate from `_flags` as that struct is compared to `0` for testing. The `_boolFlags` struct is just storing other `BOOL`s.

* rename struct fields as suggested in garret's review.
2019-05-07 09:56:11 -07:00
Greg Bolsinga c3e608b04e Shrink _ASCollectionPendingState from 144 to 128 bytes, a 12.5% reduction (#1485)
* Shrink _ASCollectionPendingState from 144 to 128 bytes, a 12.5% reduction

These objects accumulate in the heap, so reducing their size will allow more to accumulate before memory warnings.

Group the `BOOL`s into a struct. Shrink the various stored `enum`s to fit the size of their contents. Move the ivars around so that the smaller `enum` are near eachother and the bitfield struct.

* address review comments. move enums out. add comment. rename struct to _flags

* fix a missing rename
2019-05-07 09:50:36 -07:00
Huy Nguyen bf82b56253 Ship ASExperimentalFixRangeController (#1486) 2019-05-06 17:20:16 -07:00
Huy Nguyen e5bb7a6903 Minor update in change log #changelog (#1492) 2019-05-06 12:50:39 -07:00
Andrew Monshizadeh 6832175537 Clean up documentation issues around periods (#1490)
There were so unnecessary `'` around periods for some reason. Just deleting those because they are distracting.
2019-05-06 09:51:47 -07:00
Huy Nguyen ac1704e32d Cut version 2.8.1 (#1491) 2019-05-06 08:36:36 -07:00
Adlai Holler 64c43c0ded Add a new "global drawing" experiment to use UIGraphicsRenderer (#1469)
* Add a new "global drawing" experiment to use UIGraphicsRenderer everywhere, when available

* Fix logic

* Use preferredFormat
2019-05-02 20:42:23 -07:00
Greg Bolsinga ce1e1956f4 Ensure ASControlMode properties lock before accessing their ivars (#1476)
Enable `#pragma clang diagnostic error "-Wobjc-missing-property-synthesis"` for this file.
2019-05-01 12:40:48 -07:00
Greg Bolsinga d6061f4390 Make sure all ASDisplayNode properties have backing ivars for consistency. (#1475)
* Make sure all ASDisplayNodes have backing ivars for consistency.

Found this by enabling #pragma clang diagnostic error "-Wobjc-missing-property-synthesis" for ASDisplayNode. One property is unused, saving 8 bytes of heap space per instance on 64-bit builds. Implement setter/getters for these properties, and add appropriate locking. add the warning as error to the build for this file.
2019-04-30 15:56:03 -07:00
Adlai Holler 15fb7e0c1f Fix open context bug introduced in #1458 (#1468) 2019-04-25 15:38:40 -07:00
Michael Schneider 0cfafca9f6 Passthrough pagingEnabled for ASCollectionNode / ASTableNode (#1466)
* Passthrough pagingEnabled for ASCollectionNode and ASTableNode

* Add tvOS handling
2019-04-25 14:02:10 -07:00
Michael Zuccarino bb6c89e3ba Cover the other background dealloc surfaces (#1464) 2019-04-23 12:15:23 -07:00
Adlai Holler 4d524495b3 Remove ASEventLog (#1460)
* Remove ASEventLog. We'll focus on ASLog for the future, possibly making it triggerable on a per-node basis

* See ya!

* Hello semicolon

* Remove refs to gone tree methods

* Fix

* Remove irrelevant change, kick CI

* Clean up
2019-04-23 10:33:44 -07:00
Adlai Holler 5143941e49 Drop support for Xcode 8 and fix some compiler warnings (#1463) 2019-04-23 08:02:21 -07:00