Compare commits

..

12 Commits

Author SHA1 Message Date
Emil Sjolander
f36f545d75 Add an anchor to the android platform regex
Summary: This prevents android from matching in the middle of a platform.

Reviewed By: gkassabli

Differential Revision: D4306164

fbshipit-source-id: 7f62a6a017724f8f6741d3e53b5fbe0650c8c88e
2016-12-10 17:37:12 -08:00
Joel Marcey
8fcd544c81 A bit more syncing after the name change 2016-12-10 17:31:11 -08:00
Emil Sjolander
73662ebf83 example license 2016-12-07 17:41:50 +00:00
Emil Sjolander
47a8ec06a1 Add sample project for YogaKit 2016-12-07 17:27:25 +00:00
Emil Sjolander
b611fac20b update naming and fix test 2016-12-07 16:18:13 +00:00
Emil Sjolander
b11155423c Rename directories
Reviewed By: gkassabli

Differential Revision: D4284681

Summary: Rename csslayout directories to yoga

fbshipit-source-id: f0c6855c2c6e4389b7867f48f72cbb697830fc5a
2016-12-07 05:22:52 -08:00
Emil Sjolander
40371cbf2d Remove init from api
Summary: Both New and Reset already call init internally. No reason to expose this function

Reviewed By: gkassabli

Differential Revision: D4276177

fbshipit-source-id: c4404d0534f381dfacee0625b2847d38de58e038
2016-12-06 14:52:34 -08:00
Emil Sjolander
613590b0d8 Ignore csharp test dependencies which are downloaded on the fly
Summary: Running csharp tests should not result in uncommited files.

Reviewed By: splhack

Differential Revision: D4271411

fbshipit-source-id: abf6c69555ed657356a9426ca37864f8c2eaa78f
2016-12-05 12:37:36 -08:00
Emil Sjolander
4710a65f7a Fix an error initializing needsCrossTrailingPos
Summary: https://github.com/facebook/css-layout/pull/259

Reviewed By: gkassabli

Differential Revision: D4271422

fbshipit-source-id: e8d72af742d96829684958780eb56e2c375df20c
2016-12-05 09:37:38 -08:00
Emil Sjolander
901f65ca05 Fix prefix typo in YogaKit
Summary: Forgot to update this in rename.

Reviewed By: dshahidehpour, gkassabli

Differential Revision: D4271399

fbshipit-source-id: cf354928a8839a864e9961e091d9f48840a5d4d4
2016-12-05 08:07:41 -08:00
Emil Sjolander
72cf6806de Add #pragma once and extern C to YGEnums.h
Summary: Makes YGEnums.h header looks like other Yoga headers

Reviewed By: gkassabli

Differential Revision: D4274156

fbshipit-source-id: 9fa0ae146bb9e5bd40d93fa3c56f83424ebd2bf9
2016-12-05 05:07:37 -08:00
Emil Sjolander
1b7ae2ed3d Update java package name to yoga
Summary: Update package name of java code to refer to yoga instead of csslayout. Still need to change the name of the folder where this code resides but that requires update github sync scripts etc so it is safer and easier to split these diffs apart.

Differential Revision: D4271420

fbshipit-source-id: b3cf150569a2331868410339cd19e5c694f2059e
2016-12-05 03:07:33 -08:00
110 changed files with 946 additions and 343 deletions

View File

@@ -21,9 +21,9 @@ before_install:
- export PATH=$JAVA_HOME/bin:$PATH
script:
- buck test //:CSSLayout
- buck test //:yoga
- buck test //java:java
- buck test //YogaKit:YogaKit --config cxx.default_platform=iphonesimulator-x86_64 --config cxx.cflags=-DTRAVIS_CI
- buck test //YogaKit:YogaKitTests --config cxx.default_platform=iphonesimulator-x86_64 --config cxx.cflags=-DTRAVIS_CI
- sh csharp/tests/Facebook.Yoga/test_macos.sh
- buck run //benchmark:benchmark
- git checkout HEAD^

15
BUCK
View File

@@ -24,25 +24,26 @@ COMPILER_FLAGS = BASE_COMPILER_FLAGS + ['-std=c11', '-fPIC']
TEST_COMPILER_FLAGS = BASE_COMPILER_FLAGS + GMOCK_OVERRIDE_FLAGS + ['-std=c++11']
cxx_library(
name = 'CSSLayout',
srcs = glob(['CSSLayout/*.c']),
tests=[':tests'],
exported_headers = subdir_glob([('', 'CSSLayout/*.h')]),
name = 'yoga',
soname = 'libyogacore.$(ext)',
srcs = glob(['yoga/*.c']),
tests=[':YogaTests'],
exported_headers = subdir_glob([('', 'yoga/*.h')]),
header_namespace = '',
compiler_flags = COMPILER_FLAGS,
deps = [] if THIS_IS_FBOBJC else [
csslayout_dep('lib/fb:ndklog'),
yoga_dep('lib/fb:ndklog'),
],
visibility = ['PUBLIC'],
)
cxx_test(
name = 'tests',
name = 'YogaTests',
contacts = ['emilsj@fb.com'],
srcs = glob(['tests/*.cpp']),
compiler_flags = TEST_COMPILER_FLAGS,
deps = [
':CSSLayout',
':yoga',
GTEST_TARGET,
],
visibility = ['PUBLIC'],

View File

@@ -1,10 +1,7 @@
# Contributing to css-layout
# Contributing to yoga
We want to make contributing to this project as easy and transparent as
possible.
## Our Development Process
All the development is happening on GitHub first and we have internal tools to sync down to Facebook codebase.
## Pull Requests
We actively welcome your pull requests.
1. Fork the repo and create your branch from `master`.
@@ -32,5 +29,5 @@ outlined on that page and do not file a public issue.
* format.sh
## License
By contributing to css-layout, you agree that your contributions will be licensed
By contributing to yoga, you agree that your contributions will be licensed
under its BSD license.

View File

@@ -1,6 +1,6 @@
BSD License
For css-layout software
For yoga software
Copyright (c) 2014-present, Facebook, Inc. All rights reserved.

9
LICENSE-examples Normal file
View File

@@ -0,0 +1,9 @@
The examples provided by Facebook are for non-commercial testing and evaluation
purposes only. Facebook reserves all rights not expressly granted.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
FACEBOOK BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

View File

@@ -1,6 +1,6 @@
Additional Grant of Patent Rights Version 2
"Software" means the CSS Layout software distributed by Facebook, Inc.
"Software" means the yoga software distributed by Facebook, Inc.
Facebook, Inc. (“Facebook”) hereby grants to each recipient of the Software
(“you”) a perpetual, worldwide, royalty-free, non-exclusive, irrevocable

164
README.md
View File

@@ -1,162 +1,28 @@
# CSSLayout [![Build Status](https://travis-ci.org/facebook/css-layout.svg?branch=master)](https://travis-ci.org/facebook/css-layout)
# Yoga [![Build Status](https://travis-ci.org/facebook/yoga.svg?branch=master)](https://travis-ci.org/facebook/yoga)
## NOTICE
A lot is changing this week in the API regarding naming. We suggest you hold off updating to the latest version of the code until this notice is gone. Expect it to take about a week.
## Building
Yoga builds with [buck](https://buckbuild.com). Make sure you install buck before contributing to Yoga. Yoga's main implementation is in C, with bindings to supported languages and frameworks. When making changes to Yoga please ensure the changes are also propagated to these bindings when applicable.
## Goals
CSSLayout is a cross-platform implementation of flexbox. The goal of CSSLayout is allow native developers to have the same expressive layout system as developers developing for the modern web are used to. CSSLayout allows developers for web, android, iOS, and windows to use the same layout primitives across platforms. This saves time, increases collaboration between platform teams, and makes it easier for developers to work on multiple platforms.
## Testing
For any changes you make you should ensure that all the tests are passing. In case you make any fixes or additions to the library please also add tests for that change to ensure we don't break anything in the future. Tests are located in the `tests` directory. Run the tests by executing `buck test //:yoga`.
The goal of CSSLayout is not to re-implement all of css. CSSLayout only targets flexbox, and does not have any plans on implementing support for tables, floats, or any other css concepts. CSSLayout also does not plan on supporting styling properties which do not affect layout such as color or background properties.
## Differences from web
CSSLayout tries to stay as close as possible to the web implementation of flexbox. There are however certain cases where CSSLayout differs from the web implementation.
### Default values
CSSLayout has chosen to make changes to the default values of certain properties. These default values were chosen based on our usage of the library. When testing layout with tools such as JSFiddle you can apply the following css style to ensure the defaults match those of CSSLayout. Or fork the [following JSFiddle](http://jsfiddle.net/vjeux/y11txxv9/).
```css
div, span {
box-sizing: border-box;
position: relative;
display: flex;
flex-direction: column;
align-items: stretch;
flex-shrink: 0;
align-content: flex-start;
border: 0 solid black;
margin: 0;
padding: 0;
min-width: 0;
}
```
- `box-sizing: border-box` is the most convenient way to express the relation between `width` and `borderWidth`.
- Everything is `display: flex` by default. All the behaviors of `block` and `inline-block` can be expressed in term of `flex` but not the opposite.
- All the flex elements are oriented from top to bottom, left to right and do not shrink. This is how things are laid out using the default CSS settings and what you'd expect.
- Everything is `position: relative`. This makes `position: absolute` target the direct parent and not some parent which is either `relative` or `absolute`. If you want to position an element relative to something else, you should move it in the DOM instead of relying of CSS. It also makes `top, left, right, bottom` do something when not specifying `position: absolute`.
### Size units
CSSLayout currently only supports pixel sizes. The reason being that we have not seen the need for any other units. We would like to support percentage units sometime in the future.
### -start and -end properties
We think supporting RTL locales is very important. Therefor CSSLayout supports non-standards -start and -end suffixed versions of margin, padding, border, and position.
## Usage
### C
The full API can be found in `CSSLayout/CSSLayout.h`.
```c
CSSNodeRef root = CSSNodeNew();
CSSNodeStyleSetWidth(root, 100);
CSSNodeStyleSetHeight(root, 100);
for (uint32_t i = 0; i < 10; i++) {
CSSNodeRef child = CSSNodeNew();
CSSNodeStyleSetHeight(child, 10);
CSSNodeInsertChild(root, child, 0);
}
CSSNodeCalculateLayout(root, YGUndefined, YGUndefined, YGDirectionLTR);
// Get for resulting layout
CSSNodeLayoutGetLeft(root);
CSSNodeLayoutGetTop(root);
CSSNodeLayoutGetWidth(root);
CSSNodeLayoutGetHeight(root);
```
### Java
The full API can be found in `java/com/facebook/csslayout/CSSNode.java`.
```java
CSSNode root = new CSSNode();
root.setStyleWidth(100);
root.setStyleHeight(100);
for (int i = 0; i < 10; i++) {
CSSNode child = new CSSNode();
child.setStyleHeight(10);
root.addChildAt(child, 0);
}
root.calculateLayout(new CSSLayoutContext());
// Get for resulting layout
root.getLayoutX();
root.getLayoutY();
root.getLayoutWidth();
root.getLayoutHeight();
```
### UIKit
The full API can be found in `YogaKit/UIView+Yoga.h`.
```objective-c
UIView *root = [UIView new];
[root yg_setUsesYoga:YES];
[root yg_setWidth:100];
[root yg_setHeight:100];
for (NSUInteger i = 0; i < 10; i++) {
UIView *child = [UIView new];
[child yg_setUsesYoga:YES];
[child yg_setHeight:10];
[root addSubview:child];
}
// Resulting layout will be set on the UIView hierarchy frames.
[root yg_applyLayout];
```
### .NET
The full API can be found in `csharp/Facebook.CSSLayout/CSSNode.cs`.
```csharp
var root = new CSSNode();
root.StyleWidth = 100;
root.StyleHeight = 100;
for (var i = 0; i < 10; i++)
{
var child = new CSSNode();
child.StyleHeight = 10;
root.Insert(0, child);
}
// Get for resulting layout
root.LayoutX;
root.LayoutY;
root.LayoutWidth;
root.LayoutHeight;
```
## Contributing
To contribute to CSSLayout you need to first install [buck](https://buckbuild.com) which is the build system used by CSSLayout. CSSLayout is implemented in C with language bindings for Java, Objective-C, and .NET. When making changes to `CSSLayout/CSSLayout.h` please ensure to update `java/jni/CSSJNI.h`, `java/com/facebook/csslayout/CSSNode.java`, `uikit/CSSLayout/UIView+CSSLayout.m`, and `csharp/Facebook.CSSLayout/CSSNode.cs` to reflect the API change. Before submitting any code please run `format.sh` to ensure the code matches the project's code style.
Before making any larger changes to CSSLayout please open an issue with a RFC so the changes can be discussed first. Generally we are very open to changes and improvements that will benefit the community.
### Testing
For any changes you make you should ensure that all the tests are passing. In case you make any fixes or additions to the library please also add at least one test to ensure we don't break anything in the future. Tests are located in `tests/CSSLayoutTest.cpp`. Run the tests by executing `buck test //:CSSLayout`.
Instead of manually writing a test which ensures parity with web implementations of flexbox you can run `gentest/gentest.rb` to generated a test for you. You can write html which you want to verify in CSSLayout, in `gentest/fixtures` folder, such as the following.
Instead of manually writing a test which ensures parity with web implementations of Flexbox you can run `gentest/gentest.rb` to generated a test for you. You can write html which you want to verify in Yoga, in `gentest/fixtures` folder, such as the following.
```html
<div style="width: 100px; height: 100px; align-items: center;">
<div id="my_test" style="width: 100px; height: 100px; align-items: center;">
<div style="width: 50px; height: 50px;"></div>
</div>
```
Run `gentest/gentest.rb` to generate test code and re-run `buck test //:CSSLayout` to validate the behavior. One test case will be generated for every root `div` in the input html.
Run `gentest/gentest.rb` to generate test code and re-run `buck test //:yoga` to validate the behavior. One test case will be generated for every root `div` in the input html.
You may need to install the latest watir-webdriver gem (`gem install watir-webdriver`) and [ChromeDriver](https://sites.google.com/a/chromium.org/chromedriver/) to run `gentest/gentest.rb` Ruby script.
#### .NET
.NET testing is not integrated in buck yet, you might need to set up .NET testing environment. We have a script which to launch C# test on macOS, `csharp/tests/Facebook.CSSLayout/test_macos.sh`.
### .NET
.NET testing is not integrated in buck yet, you might need to set up .NET testing environment. We have a script which to launch C# test on macOS, `csharp/tests/Facebook.Yoga/test_macos.sh`.
### Benchmarks
Benchmarks are located in `benchmarks/CSSBenchmark.c` and can be run with `buck run //benchmarks:benchmarks`. If you think your change has affected performance please run this before and after your change to validate that nothing has regressed.
## Code style
For the main C implementation of Yoga clang-format is used to ensure a consistent code style. Please run `bash format.sh` before submitting a pull request. For other languages just try to follow the current code style.
## Benchmarks
Benchmarks are located in `benchmarks/YGBenchmark.c` and can be run with `buck run //benchmarks:benchmarks`. If you think your change has affected performance please run this before and after your change to validate that nothing has regressed. Benchmarks are run on every commit in CI.

View File

@@ -1,5 +1,5 @@
CSSLAYOUT_ROOT = '//...'
YOGA_ROOT = '//...'
INFER_ANNOTATIONS_TARGET = '//lib/infer-annotations:infer-annotations'
JSR_305_TARGET = '//lib/jsr-305:jsr-305'
JUNIT_TARGET = '//lib/junit:junit'
@@ -12,12 +12,12 @@ FBJNI_TARGET = '//lib/fb:fbjni'
THIS_IS_FBOBJC = False
CXX_LIBRARY_WHITELIST = [
'//:CSSLayout',
'//:yoga',
'//lib/fb:fbjni',
'//java:jni',
]
def csslayout_dep(dep):
def yoga_dep(dep):
return '//' + dep
class allow_unsafe_import:

View File

@@ -7,7 +7,7 @@
include_defs('//YOGA_DEFS')
UIKIT_CSSLAYOUT_COMPILER_FLAGS = [
COMPILER_FLAGS = [
'-fobjc-arc',
'-Wconditional-uninitialized',
'-Wdangling-else',
@@ -29,8 +29,7 @@ UIKIT_CSSLAYOUT_COMPILER_FLAGS = [
apple_library(
name = 'YogaKit',
compiler_flags = UIKIT_CSSLAYOUT_COMPILER_FLAGS,
tests = [':YogaKitTests'],
compiler_flags = COMPILER_FLAGS,
srcs = glob(['*.m']),
exported_headers = glob(['*.h']),
frameworks = [
@@ -38,14 +37,14 @@ apple_library(
'$SDKROOT/System/Library/Frameworks/UIKit.framework',
],
deps = [
csslayout_dep(':CSSLayout'),
yoga_dep(':yoga'),
],
visibility = ['PUBLIC'],
)
apple_test(
name = 'YogaKitTests',
compiler_flags = UIKIT_CSSLAYOUT_COMPILER_FLAGS,
compiler_flags = COMPILER_FLAGS,
info_plist = 'Tests/Info.plist',
srcs = glob(['Tests/**/*.m']),
frameworks = [

View File

@@ -8,7 +8,7 @@
*/
#import <UIKit/UIKit.h>
#import <CSSLayout/Yoga.h>
#import <yoga/Yoga.h>
@interface UIView (Yoga)

View File

@@ -19,7 +19,7 @@
+ (void)initialize
{
YogaSetExperimentalFeatureEnabled(YGExperimentalFeatureWebFlexBasis, true);
YGSetExperimentalFeatureEnabled(YGExperimentalFeatureWebFlexBasis, true);
}
- (instancetype)init

View File

@@ -0,0 +1,376 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
13687D481DF8748400E7C260 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13687D471DF8748400E7C260 /* main.m */; };
13687D4B1DF8748400E7C260 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13687D4A1DF8748400E7C260 /* AppDelegate.m */; };
13687D4E1DF8748400E7C260 /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 13687D4D1DF8748400E7C260 /* ViewController.m */; };
13687D531DF8748400E7C260 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13687D521DF8748400E7C260 /* Assets.xcassets */; };
13687D781DF878C600E7C260 /* YGEnums.h in yoga */ = {isa = PBXBuildFile; fileRef = 13687D5E1DF8778F00E7C260 /* YGEnums.h */; };
13687D791DF878C600E7C260 /* YGMacros.h in yoga */ = {isa = PBXBuildFile; fileRef = 13687D5F1DF8778F00E7C260 /* YGMacros.h */; };
13687D7A1DF878C600E7C260 /* Yoga.h in yoga */ = {isa = PBXBuildFile; fileRef = 13687D631DF8778F00E7C260 /* Yoga.h */; };
13687D7C1DF878DD00E7C260 /* UIView+Yoga.h in YogaKit */ = {isa = PBXBuildFile; fileRef = 13687D691DF8778F00E7C260 /* UIView+Yoga.h */; };
13687D801DF87CEC00E7C260 /* UIView+Yoga.m in Sources */ = {isa = PBXBuildFile; fileRef = 13687D6A1DF8778F00E7C260 /* UIView+Yoga.m */; };
13687D811DF87CF200E7C260 /* YGNodeList.c in Sources */ = {isa = PBXBuildFile; fileRef = 13687D601DF8778F00E7C260 /* YGNodeList.c */; };
13687D821DF87CF200E7C260 /* Yoga.c in Sources */ = {isa = PBXBuildFile; fileRef = 13687D621DF8778F00E7C260 /* Yoga.c */; };
13687D851DF87D1E00E7C260 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 13687D841DF87D1E00E7C260 /* UIKit.framework */; };
13687D871DF87D2400E7C260 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 13687D861DF87D2400E7C260 /* Foundation.framework */; };
/* End PBXBuildFile section */
/* Begin PBXCopyFilesBuildPhase section */
13687D771DF878A000E7C260 /* yoga */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = include/yoga;
dstSubfolderSpec = 16;
files = (
13687D781DF878C600E7C260 /* YGEnums.h in yoga */,
13687D791DF878C600E7C260 /* YGMacros.h in yoga */,
13687D7A1DF878C600E7C260 /* Yoga.h in yoga */,
);
name = yoga;
runOnlyForDeploymentPostprocessing = 0;
};
13687D7B1DF878CE00E7C260 /* YogaKit */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = include/YogaKit;
dstSubfolderSpec = 16;
files = (
13687D7C1DF878DD00E7C260 /* UIView+Yoga.h in YogaKit */,
);
name = YogaKit;
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */
13687D431DF8748400E7C260 /* YogaKitSample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = YogaKitSample.app; sourceTree = BUILT_PRODUCTS_DIR; };
13687D471DF8748400E7C260 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
13687D491DF8748400E7C260 /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
13687D4A1DF8748400E7C260 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
13687D4C1DF8748400E7C260 /* ViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ViewController.h; sourceTree = "<group>"; };
13687D4D1DF8748400E7C260 /* ViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ViewController.m; sourceTree = "<group>"; };
13687D521DF8748400E7C260 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
13687D571DF8748400E7C260 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
13687D5E1DF8778F00E7C260 /* YGEnums.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = YGEnums.h; sourceTree = "<group>"; };
13687D5F1DF8778F00E7C260 /* YGMacros.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = YGMacros.h; sourceTree = "<group>"; };
13687D601DF8778F00E7C260 /* YGNodeList.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = YGNodeList.c; sourceTree = "<group>"; };
13687D611DF8778F00E7C260 /* YGNodeList.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = YGNodeList.h; sourceTree = "<group>"; };
13687D621DF8778F00E7C260 /* Yoga.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = Yoga.c; sourceTree = "<group>"; };
13687D631DF8778F00E7C260 /* Yoga.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Yoga.h; sourceTree = "<group>"; };
13687D691DF8778F00E7C260 /* UIView+Yoga.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "UIView+Yoga.h"; sourceTree = "<group>"; };
13687D6A1DF8778F00E7C260 /* UIView+Yoga.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "UIView+Yoga.m"; sourceTree = "<group>"; };
13687D841DF87D1E00E7C260 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
13687D861DF87D2400E7C260 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
13687D401DF8748300E7C260 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
13687D871DF87D2400E7C260 /* Foundation.framework in Frameworks */,
13687D851DF87D1E00E7C260 /* UIKit.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
13687D3A1DF8748300E7C260 = {
isa = PBXGroup;
children = (
13687D5D1DF8778F00E7C260 /* yoga */,
13687D641DF8778F00E7C260 /* YogaKit */,
13687D451DF8748400E7C260 /* YogaKitSample */,
13687D441DF8748400E7C260 /* Products */,
13687D831DF87D1E00E7C260 /* Frameworks */,
);
sourceTree = "<group>";
};
13687D441DF8748400E7C260 /* Products */ = {
isa = PBXGroup;
children = (
13687D431DF8748400E7C260 /* YogaKitSample.app */,
);
name = Products;
sourceTree = "<group>";
};
13687D451DF8748400E7C260 /* YogaKitSample */ = {
isa = PBXGroup;
children = (
13687D491DF8748400E7C260 /* AppDelegate.h */,
13687D4A1DF8748400E7C260 /* AppDelegate.m */,
13687D4C1DF8748400E7C260 /* ViewController.h */,
13687D4D1DF8748400E7C260 /* ViewController.m */,
13687D521DF8748400E7C260 /* Assets.xcassets */,
13687D571DF8748400E7C260 /* Info.plist */,
13687D461DF8748400E7C260 /* Supporting Files */,
);
path = YogaKitSample;
sourceTree = "<group>";
};
13687D461DF8748400E7C260 /* Supporting Files */ = {
isa = PBXGroup;
children = (
13687D471DF8748400E7C260 /* main.m */,
);
name = "Supporting Files";
sourceTree = "<group>";
};
13687D5D1DF8778F00E7C260 /* yoga */ = {
isa = PBXGroup;
children = (
13687D5E1DF8778F00E7C260 /* YGEnums.h */,
13687D5F1DF8778F00E7C260 /* YGMacros.h */,
13687D601DF8778F00E7C260 /* YGNodeList.c */,
13687D611DF8778F00E7C260 /* YGNodeList.h */,
13687D621DF8778F00E7C260 /* Yoga.c */,
13687D631DF8778F00E7C260 /* Yoga.h */,
);
name = yoga;
path = ../../yoga;
sourceTree = "<group>";
};
13687D641DF8778F00E7C260 /* YogaKit */ = {
isa = PBXGroup;
children = (
13687D691DF8778F00E7C260 /* UIView+Yoga.h */,
13687D6A1DF8778F00E7C260 /* UIView+Yoga.m */,
);
name = YogaKit;
path = ..;
sourceTree = "<group>";
};
13687D831DF87D1E00E7C260 /* Frameworks */ = {
isa = PBXGroup;
children = (
13687D861DF87D2400E7C260 /* Foundation.framework */,
13687D841DF87D1E00E7C260 /* UIKit.framework */,
);
name = Frameworks;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
13687D421DF8748300E7C260 /* YogaKitSample */ = {
isa = PBXNativeTarget;
buildConfigurationList = 13687D5A1DF8748400E7C260 /* Build configuration list for PBXNativeTarget "YogaKitSample" */;
buildPhases = (
13687D771DF878A000E7C260 /* yoga */,
13687D7B1DF878CE00E7C260 /* YogaKit */,
13687D3F1DF8748300E7C260 /* Sources */,
13687D401DF8748300E7C260 /* Frameworks */,
13687D411DF8748300E7C260 /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = YogaKitSample;
productName = YogaKitSample;
productReference = 13687D431DF8748400E7C260 /* YogaKitSample.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
13687D3B1DF8748300E7C260 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0810;
ORGANIZATIONNAME = facebook;
TargetAttributes = {
13687D421DF8748300E7C260 = {
CreatedOnToolsVersion = 8.1;
ProvisioningStyle = Automatic;
};
};
};
buildConfigurationList = 13687D3E1DF8748300E7C260 /* Build configuration list for PBXProject "YogaKitSample" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = 13687D3A1DF8748300E7C260;
productRefGroup = 13687D441DF8748400E7C260 /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
13687D421DF8748300E7C260 /* YogaKitSample */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
13687D411DF8748300E7C260 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
13687D531DF8748400E7C260 /* Assets.xcassets in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
13687D3F1DF8748300E7C260 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
13687D801DF87CEC00E7C260 /* UIView+Yoga.m in Sources */,
13687D4E1DF8748400E7C260 /* ViewController.m in Sources */,
13687D4B1DF8748400E7C260 /* AppDelegate.m in Sources */,
13687D821DF87CF200E7C260 /* Yoga.c in Sources */,
13687D811DF87CF200E7C260 /* YGNodeList.c in Sources */,
13687D481DF8748400E7C260 /* main.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin XCBuildConfiguration section */
13687D581DF8748400E7C260 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_SUSPICIOUS_MOVES = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.1;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
};
name = Debug;
};
13687D591DF8748400E7C260 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_SUSPICIOUS_MOVES = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.1;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
VALIDATE_PRODUCT = YES;
};
name = Release;
};
13687D5B1DF8748400E7C260 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
INFOPLIST_FILE = YogaKitSample/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.facebook.YogaKitSample;
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Debug;
};
13687D5C1DF8748400E7C260 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
INFOPLIST_FILE = YogaKitSample/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.facebook.YogaKitSample;
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
13687D3E1DF8748300E7C260 /* Build configuration list for PBXProject "YogaKitSample" */ = {
isa = XCConfigurationList;
buildConfigurations = (
13687D581DF8748400E7C260 /* Debug */,
13687D591DF8748400E7C260 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
13687D5A1DF8748400E7C260 /* Build configuration list for PBXNativeTarget "YogaKitSample" */ = {
isa = XCConfigurationList;
buildConfigurations = (
13687D5B1DF8748400E7C260 /* Debug */,
13687D5C1DF8748400E7C260 /* Release */,
);
defaultConfigurationIsVisible = 0;
};
/* End XCConfigurationList section */
};
rootObject = 13687D3B1DF8748300E7C260 /* Project object */;
}

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<Workspace
version = "1.0">
<FileRef
location = "self:YogaKitSample.xcodeproj">
</FileRef>
</Workspace>

View File

@@ -0,0 +1,91 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0810"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "13687D421DF8748300E7C260"
BuildableName = "YogaKitSample.app"
BlueprintName = "YogaKitSample"
ReferencedContainer = "container:YogaKitSample.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "13687D421DF8748300E7C260"
BuildableName = "YogaKitSample.app"
BlueprintName = "YogaKitSample"
ReferencedContainer = "container:YogaKitSample.xcodeproj">
</BuildableReference>
</MacroExpansion>
<AdditionalOptions>
</AdditionalOptions>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "13687D421DF8748300E7C260"
BuildableName = "YogaKitSample.app"
BlueprintName = "YogaKitSample"
ReferencedContainer = "container:YogaKitSample.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "13687D421DF8748300E7C260"
BuildableName = "YogaKitSample.app"
BlueprintName = "YogaKitSample"
ReferencedContainer = "container:YogaKitSample.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SchemeUserState</key>
<dict>
<key>YogaKitSample.xcscheme</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
</dict>
<key>SuppressBuildableAutocreation</key>
<dict>
<key>13687D421DF8748300E7C260</key>
<dict>
<key>primary</key>
<true/>
</dict>
</dict>
</dict>
</plist>

View File

@@ -0,0 +1,16 @@
/**
* Copyright 2014-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the license found in the
* LICENSE-examples file in the root directory of this source tree.
*/
#import <UIKit/UIKit.h>
@interface AppDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
@end

View File

@@ -0,0 +1,27 @@
/**
* Copyright 2014-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the license found in the
* LICENSE-examples file in the root directory of this source tree.
*/
#import "AppDelegate.h"
#import "ViewController.h"
@interface AppDelegate ()
@end
@implementation AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
self.window.rootViewController = [ViewController new];
self.window.backgroundColor = [UIColor whiteColor];
[self.window makeKeyAndVisible];
return YES;
}
@end

View File

@@ -0,0 +1,48 @@
{
"images" : [
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

View File

@@ -0,0 +1,36 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UILaunchStoryboardName</key>
<string></string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
</dict>
</plist>

View File

@@ -0,0 +1,15 @@
/**
* Copyright 2014-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the license found in the
* LICENSE-examples file in the root directory of this source tree.
*/
#import <UIKit/UIKit.h>
@interface ViewController : UIViewController
@end

View File

@@ -0,0 +1,60 @@
/**
* Copyright 2014-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the license found in the
* LICENSE-examples file in the root directory of this source tree.
*/
#import "ViewController.h"
#import <YogaKit/UIView+Yoga.h>
@interface ViewController ()
@end
@implementation ViewController
- (void)viewDidLoad
{
UIView *root = self.view;
root.backgroundColor = [UIColor redColor];
[root yg_setUsesYoga:YES];
[root yg_setWidth:self.view.bounds.size.width];
[root yg_setHeight:self.view.bounds.size.height];
[root yg_setAlignItems:YGAlignCenter];
[root yg_setJustifyContent:YGJustifyCenter];
UIView *child1 = [UIView new];
child1.backgroundColor = [UIColor blueColor];
[child1 yg_setUsesYoga:YES];
[child1 yg_setWidth:100];
[child1 yg_setHeight:100];
UIView *child2 = [UIView new];
child2.backgroundColor = [UIColor greenColor];
child2.frame = (CGRect) {
.size = {
.width = 200,
.height = 100,
}
};
UIView *child3 = [UIView new];
child3.backgroundColor = [UIColor yellowColor];
child3.frame = (CGRect) {
.size = {
.width = 100,
.height = 100,
}
};
[child2 addSubview:child3];
[root addSubview:child1];
[root addSubview:child2];
[root yg_applyLayout];
}
@end

View File

@@ -0,0 +1,16 @@
/**
* Copyright 2014-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the license found in the
* LICENSE-examples file in the root directory of this source tree.
*/
#import <UIKit/UIKit.h>
#import "AppDelegate.h"
int main(int argc, char * argv[]) {
@autoreleasepool {
return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
}
}

View File

@@ -21,7 +21,7 @@ cxx_binary(
'-std=c11',
],
deps = [
csslayout_dep(':CSSLayout'),
yoga_dep(':yoga'),
],
visibility = ['PUBLIC'],
)

View File

@@ -9,7 +9,7 @@
#include "YGBenchmark.h"
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
static YGSize _measure(YGNodeRef node,
float width,

7
csharp/.gitignore vendored
View File

@@ -30,6 +30,11 @@ bld/
# MSTest test Results
[Tt]est[Rr]esult*/
[Bb]uild[Ll]og.*
csharp/tests/Facebook.Yoga/NUnit-[0-9\.]+/
csharp/tests/Facebook.Yoga/YogaTest.dll
csharp/tests/Facebook.Yoga/YogaTest.dll.mdb
csharp/tests/Facebook.Yoga/libyoga.dylib
csharp/tests/Facebook.Yoga/libyoga.dylib.dSYM/
# NUNIT
*.VisualState.xml
@@ -262,4 +267,4 @@ paket-files/
# Python Tools for Visual Studio (PTVS)
__pycache__/
*.pyc
*.pyc

View File

@@ -34,6 +34,11 @@ bld/
# NUNIT
*.VisualState.xml
TestResult.xml
csharp/tests/Facebook.Yoga/NUnit-[0-9\.]+/
csharp/tests/Facebook.Yoga/YogaTest.dll
csharp/tests/Facebook.Yoga/YogaTest.dll.mdb
csharp/tests/Facebook.Yoga/libyoga.dylib
csharp/tests/Facebook.Yoga/libyoga.dylib.dSYM/
# Build Results of an ATL Project
[Dd]ebugPS/
@@ -262,4 +267,4 @@ paket-files/
# Python Tools for Visual Studio (PTVS)
__pycache__/
*.pyc
*.pyc

View File

@@ -6,14 +6,14 @@
# of patent rights can be found in the PATENTS file in the same directory.
csharp_library(
name = 'csslibnet46',
name = 'yogalibnet46',
dll_name = 'Facebook.Yoga.dll',
framework_ver = 'net46',
srcs = glob(['**/*.cs']),
)
csharp_library(
name = 'csslibnet45',
name = 'yogalibnet45',
dll_name = 'Facebook.Yoga.dll',
framework_ver = 'net45',
srcs = glob(['**/*.cs']),

View File

@@ -28,13 +28,13 @@ namespace Facebook.Yoga
public static extern IntPtr YGNodeNew();
[DllImport(DllName)]
public static extern void YGNodeInit(IntPtr cssNode);
public static extern void YGNodeInit(IntPtr node);
[DllImport(DllName)]
public static extern void YGNodeFree(IntPtr cssNode);
public static extern void YGNodeFree(IntPtr node);
[DllImport(DllName)]
public static extern void YGNodeReset(IntPtr cssNode);
public static extern void YGNodeReset(IntPtr node);
[DllImport(DllName)]
public static extern int YGNodeGetInstanceCount();

View File

@@ -9,7 +9,7 @@
#pragma once
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
YG_EXTERN_C_BEGIN

View File

@@ -150,16 +150,16 @@
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClInclude Include="..\..\CSSLayout\Yoga.h" />
<ClInclude Include="..\..\CSSLayout\YGMacros.h" />
<ClInclude Include="..\..\CSSLayout\YGNodeList.h" />
<ClInclude Include="..\..\yoga\Yoga.h" />
<ClInclude Include="..\..\yoga\YGMacros.h" />
<ClInclude Include="..\..\yoga\YGNodeList.h" />
<ClInclude Include="YGInterop.h" />
<ClInclude Include="stdafx.h" />
<ClInclude Include="targetver.h" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\CSSLayout\Yoga.c" />
<ClCompile Include="..\..\CSSLayout\YGNodeList.c" />
<ClCompile Include="..\..\yoga\Yoga.c" />
<ClCompile Include="..\..\yoga\YGNodeList.c" />
<ClCompile Include="YGInterop.cpp" />
<ClCompile Include="dllmain.cpp">
<CompileAsManaged Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">false</CompileAsManaged>

View File

@@ -21,13 +21,13 @@
<ClInclude Include="targetver.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\..\CSSLayout\Yoga.h">
<ClInclude Include="..\..\yoga\Yoga.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\..\CSSLayout\YGMacros.h">
<ClInclude Include="..\..\yoga\YGMacros.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\..\CSSLayout\YGNodeList.h">
<ClInclude Include="..\..\yoga\YGNodeList.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="YGInterop.h">
@@ -41,10 +41,10 @@
<ClCompile Include="dllmain.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="..\..\CSSLayout\Yoga.c">
<ClCompile Include="..\..\yoga\Yoga.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="..\..\CSSLayout\YGNodeList.c">
<ClCompile Include="..\..\yoga\YGNodeList.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="YGInterop.cpp">

View File

@@ -28,6 +28,6 @@ if [ -d $NUNIT \
rm NUnit-2.6.4.zip
fi
clang -g -Wall -Wextra -dynamiclib -o libyoga.dylib -I../../.. ../../../CSSLayout/*.c ../../Yoga/YGInterop.cpp
clang -g -Wall -Wextra -dynamiclib -o libyoga.dylib -I../../.. ../../../yoga/*.c ../../Yoga/YGInterop.cpp
mcs -debug -t:library -r:$NUNIT/nunit.framework.dll -out:YogaTest.dll *.cs ../../../csharp/Facebook.Yoga/*cs
MONO_PATH=$NUNIT mono --arch=64 --debug $NUNIT/nunit-console.exe YogaTest.dll

View File

@@ -114,9 +114,11 @@ def to_java_upper(symbol):
root = os.path.dirname(__file__)
# write out C header
with open(root + '/CSSLayout/YGEnums.h', 'w') as f:
with open(root + '/yoga/YGEnums.h', 'w') as f:
f.write(LICENSE)
remaining = len(ENUMS)
f.write('#pragma once\n\n')
f.write('#include "YGMacros.h"\n\n')
f.write('YG_EXTERN_C_BEGIN\n\n')
for name, values in ENUMS.items():
f.write('typedef enum YG%s {\n' % name)
for value in values:
@@ -126,15 +128,14 @@ with open(root + '/CSSLayout/YGEnums.h', 'w') as f:
f.write(' YG%s%s,\n' % (name, value))
f.write(' YG%sCount,\n' % name)
f.write('} YG%s;\n' % name)
if remaining > 1:
f.write('\n')
remaining = remaining - 1
f.write('\n')
f.write('YG_EXTERN_C_END\n')
# write out java files
for name, values in ENUMS.items():
with open(root + '/java/com/facebook/csslayout/Yoga%s.java' % name, 'w') as f:
with open(root + '/java/com/facebook/yoga/Yoga%s.java' % name, 'w') as f:
f.write(LICENSE)
f.write('package com.facebook.csslayout;\n\n')
f.write('package com.facebook.yoga;\n\n')
f.write('import com.facebook.proguard.annotations.DoNotStrip;\n\n')
f.write('@DoNotStrip\n')
f.write('public enum Yoga%s {\n' % name)

View File

@@ -29,7 +29,6 @@ clang-format \
SpaceAfterCStyleCast: true, \
UseTab: Never, \
}" "$@" \
-i $(dirname $0)/CSSLayout/*.{h,c,cpp} \
$(dirname $0)/tests/CSSLayoutTestUtils/*.{h,c,cpp} \
-i $(dirname $0)/yoga/*.{h,c,cpp} \
$(dirname $0)/benchmarks/*.{h,c,cpp} \
$(dirname $0)/java/jni/*.{h,c,cpp}

View File

@@ -20,7 +20,7 @@ CPPEmitter.prototype = Object.create(Emitter.prototype, {
emitPrologue:{value:function() {
this.push([
'#include <CSSLayout/Yoga.h>',
'#include <yoga/Yoga.h>',
'#include <gtest/gtest.h>',
'',
]);

View File

@@ -28,7 +28,7 @@ JavaEmitter.prototype = Object.create(Emitter.prototype, {
emitPrologue:{value:function() {
this.push([
'package com.facebook.csslayout;',
'package com.facebook.yoga;',
'',
'import org.junit.Test;',
'',

View File

@@ -40,7 +40,7 @@ Dir['fixtures/*.html'].each do |file|
f.write eval(logs[0].message.sub(/^[^"]*/, ''))
f.close
f = File.open("../java/tests/com/facebook/csslayout/#{name}.java", 'w')
f = File.open("../java/tests/com/facebook/yoga/#{name}.java", 'w')
f.write eval(logs[1].message.sub(/^[^"]*/, '')).sub('YogaTest', name)
f.close

View File

@@ -24,16 +24,16 @@ cxx_library(
deps = [
FBJNI_TARGET,
JNI_TARGET,
csslayout_dep(':CSSLayout'),
yoga_dep(':yoga'),
],
visibility = ['PUBLIC'],
)
java_library(
name = 'java',
srcs = glob(['com/facebook/csslayout/*.java']),
srcs = glob(['com/facebook/yoga/*.java']),
tests=[
csslayout_dep('java:tests'),
yoga_dep('java:tests'),
],
source = '1.7',
target = '1.7',

View File

@@ -13,5 +13,5 @@ java_library(
source = '1.7',
target = '1.7',
deps = [],
visibility = [CSSLAYOUT_ROOT],
visibility = [YOGA_ROOT],
)

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
public class YogaConstants {

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
/**
* Helpers for building measure output value.

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import javax.annotation.Nullable;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
// This only exists for legacy reasons. It will be removed sometime in the near future.
public interface YogaNodeAPI<YogaNodeType extends YogaNodeAPI> {

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import com.facebook.proguard.annotations.DoNotStrip;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <fb/fbjni.h>
#include <iostream>
@@ -58,7 +58,7 @@ static YGSize YGJNIMeasureFunc(YGNodeRef node,
float height,
YGMeasureMode heightMode) {
if (auto obj = YGNodeJobject(node)->lockLocal()) {
static auto measureFunc = findClassLocal("com/facebook/csslayout/YogaNode")
static auto measureFunc = findClassLocal("com/facebook/yoga/YogaNode")
->getMethod<jlong(jfloat, jint, jfloat, jint)>("measure");
YGTransferLayoutDirection(node, obj);
@@ -81,7 +81,7 @@ static YGSize YGJNIMeasureFunc(YGNodeRef node,
}
struct JYogaLogLevel : public JavaClass<JYogaLogLevel> {
static constexpr auto kJavaDescriptor = "Lcom/facebook/csslayout/YogaLogLevel;";
static constexpr auto kJavaDescriptor = "Lcom/facebook/yoga/YogaLogLevel;";
};
static global_ref<jobject> *jLogger;
@@ -89,7 +89,7 @@ static int YGLog(YGLogLevel level, const char *format, va_list args) {
char buffer[256];
int result = vsnprintf(buffer, sizeof(buffer), format, args);
static auto logFunc = findClassLocal("com/facebook/csslayout/YogaLogger")
static auto logFunc = findClassLocal("com/facebook/yoga/YogaLogger")
->getMethod<void(local_ref<JYogaLogLevel>, jstring)>("log");
static auto logLevelFromInt =
@@ -261,7 +261,7 @@ YG_NODE_JNI_STYLE_PROP(jfloat, float, AspectRatio);
jint JNI_OnLoad(JavaVM *vm, void *) {
return initialize(vm, [] {
registerNatives("com/facebook/csslayout/YogaNode",
registerNatives("com/facebook/yoga/YogaNode",
{
YGMakeNativeMethod(jni_YGNodeNew),
YGMakeNativeMethod(jni_YGNodeFree),

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGAbsolutePositionTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGAlignContentTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGAlignItemsTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGAlignSelfTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGBorderTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGFlexDirectionTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGFlexTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGFlexWrapTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGJustifyContentTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGMarginTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGMinMaxDimensionTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGPaddingTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGRoundingTest.html
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
package com.facebook.csslayout;
package com.facebook.yoga;
import org.junit.Test;

View File

@@ -11,9 +11,9 @@ prebuilt_cxx_library(
name = 'ndklog',
header_only = True,
exported_platform_linker_flags = [
('android.*', ['-llog']),
('^android.*', ['-llog']),
],
visibility = [CSSLAYOUT_ROOT],
visibility = [YOGA_ROOT],
)
cxx_library(

View File

@@ -23,5 +23,5 @@ cxx_library(
header_namespace = '',
compiler_flags = COMPILER_FLAGS,
deps = [],
visibility = [CSSLAYOUT_ROOT],
visibility = [YOGA_ROOT],
)

View File

@@ -17,5 +17,5 @@ java_library(
exported_deps = [
':infer-annotations-jar',
],
visibility = [CSSLAYOUT_ROOT],
visibility = [YOGA_ROOT],
)

View File

@@ -17,5 +17,5 @@ java_library(
exported_deps = [
':jsr305-jar',
],
visibility = [CSSLAYOUT_ROOT],
visibility = [YOGA_ROOT],
)

View File

@@ -17,5 +17,5 @@ java_library(
exported_deps = [
':junit-jar',
],
visibility = [CSSLAYOUT_ROOT],
visibility = [YOGA_ROOT],
)

View File

@@ -10,5 +10,5 @@ include_defs('//YOGA_DEFS')
android_prebuilt_aar(
name = 'soloader',
aar = 'soloader-0.1.0.aar',
visibility = [CSSLAYOUT_ROOT],
visibility = [YOGA_ROOT],
)

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGAbsolutePositionTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, absolute_layout_width_height_start_top) {

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGAlignContentTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, align_content_flex_start) {

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGAlignItemsTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, align_items_stretch) {

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGAlignSelfTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, align_self_center) {

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGBorderTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, border_no_size) {

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, dirty_propagation) {

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, start_overrides) {

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGFlexDirectionTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, flex_direction_column_no_height) {

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGFlexTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, flex_basis_flex_grow_column) {

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGFlexWrapTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, wrap_column) {

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGJustifyContentTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, justify_content_row_flex_start) {

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
static YGSize _measure(YGNodeRef node,

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, assert_default_values) {

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGMarginTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, margin_start) {

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
static YGSize _measureMax(YGNodeRef node,

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
struct _MeasureConstraint {

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
static YGSize _measure(YGNodeRef node,

View File

@@ -7,7 +7,7 @@
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
extern int32_t gNodeInstanceCount;

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGMinMaxDimensionTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, max_width) {

View File

@@ -9,7 +9,7 @@
// @Generated by gentest/gentest.rb from gentest/fixtures/YGPaddingTest.html
#include <CSSLayout/Yoga.h>
#include <yoga/Yoga.h>
#include <gtest/gtest.h>
TEST(YogaTest, padding_no_size) {

Some files were not shown because too many files have changed in this diff Show More