Files
yoga/android
Nick Gerleman 35f3335efc Fix yg_positionType ordinals (#1183)
Summary:
Fixes https://github.com/facebook/yoga/issues/1179

fc88b2f774 shifted ordinals for the position enum, but only updated a limited set of code for the new values. Binding generation has since been fixed, but https://github.com/facebook/yoga/issues/1179 seems to be another case where the ordinal offsetting means that `yg_positionType` of a `YogaLayout` view does not work correctly.

Update the ordinals in accordance with the ordering in YogaPositionType which the integer value is converted to.

Using "static" (the new position type) directly gives a compilation error due to it being a reserved keyword, so I added it as "position_static" along with aliases to other properties with the same naming scheme for consistency.

Pull Request resolved: https://github.com/facebook/yoga/pull/1183

Reviewed By: lunaleaps

Differential Revision: D41741955

Pulled By: NickGerleman

fbshipit-source-id: 2b035eb38d9efea19af652e5f05c02b0be402d54
2022-12-06 08:39:20 -08:00
..
2018-10-24 03:11:40 -07:00
2022-10-03 21:22:57 -07:00

YogaLayout Platform Languages Download

Installation

YogaLayout is available via jcenter:

implementation 'com.facebook.yoga.android:yoga-layout:1.16.0'

Getting Started

Check out the docs here.

We also have a sample project. To try it, clone the repo and run (with a device attached)

buck install -r android/sample

Contributing

We welcome all pull-requests! At Facebook we sync the open source version of YogaKit daily, so we're always testing the latest changes.

See the CONTRIBUTING file for how to help out.