mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
b181b7797f
Summary: Some files have crept into the repo with the old license header. These are usually from PRs that were opened prior to the re-licensing of the project. Let the script run, prior to fixing the errant files. The script outputs the following: ``` PATENTS crept into some new files? --- /dev/fd/63 2018-03-01 01:42:48.250153746 +0000 +++ /dev/fd/62 2018-03-01 01:42:48.250153746 +0000 @@ -1 +1,9 @@ +Libraries/NativeAnimation/Nodes/RCTTrackingAnimatedNode.h +Libraries/NativeAnimation/Nodes/RCTTrackingAnimatedNode.m +ReactAndroid/src/main/java/com/facebook/react/animated/TrackingAnimatedNode.java +ReactAndroid/src/main/java/com/facebook/react/views/text/CustomLetterSpacingSpan.java +ReactCommon/yoga/yoga/YGLayout.cpp +ReactCommon/yoga/yoga/YGLayout.h +ReactCommon/yoga/yoga/YGStyle.cpp +ReactCommon/yoga/yoga/YGStyle.h scripts/circleci/check_license.sh Exited with code 1 ``` Fix the headers in these files and run the script again. No output, exit code 0. Closes https://github.com/facebook/react-native/pull/18143 Reviewed By: sophiebits Differential Revision: D7119356 Pulled By: hramos fbshipit-source-id: d238e4d4a3ae320a2c8e625c2fa29690057a4814
36 lines
1.3 KiB
Java
36 lines
1.3 KiB
Java
/**
|
|
* Copyright (c) 2015-present, Facebook, Inc.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/
|
|
|
|
package com.facebook.react.animated;
|
|
|
|
import com.facebook.react.bridge.JavaOnlyMap;
|
|
import com.facebook.react.bridge.ReadableMap;
|
|
|
|
/* package */ class TrackingAnimatedNode extends AnimatedNode {
|
|
|
|
private final NativeAnimatedNodesManager mNativeAnimatedNodesManager;
|
|
private final int mAnimationId;
|
|
private final int mToValueNode;
|
|
private final int mValueNode;
|
|
private final JavaOnlyMap mAnimationConfig;
|
|
|
|
TrackingAnimatedNode(ReadableMap config, NativeAnimatedNodesManager nativeAnimatedNodesManager) {
|
|
mNativeAnimatedNodesManager = nativeAnimatedNodesManager;
|
|
mAnimationId = config.getInt("animationId");
|
|
mToValueNode = config.getInt("toValue");
|
|
mValueNode = config.getInt("value");
|
|
mAnimationConfig = JavaOnlyMap.deepClone(config.getMap("animationConfig"));
|
|
}
|
|
|
|
@Override
|
|
public void update() {
|
|
AnimatedNode toValue = mNativeAnimatedNodesManager.getNodeById(mToValueNode);
|
|
mAnimationConfig.putDouble("toValue", ((ValueAnimatedNode) toValue).getValue());
|
|
mNativeAnimatedNodesManager.startAnimatingNode(mAnimationId, mValueNode, mAnimationConfig, null);
|
|
}
|
|
}
|