Automated fixups for Instagram
Reviewed By: dreiss Differential Revision: D6168048 fbshipit-source-id: 0e51319d93fd697db01ea3933f48cd06a6ffac12
This commit is contained in:
parent
bbc90b4dc2
commit
dd016f334c
|
@ -12,6 +12,7 @@ android_library(
|
||||||
provided_deps = [
|
provided_deps = [
|
||||||
react_native_dep("third-party/android/support/v4:lib-support-v4"),
|
react_native_dep("third-party/android/support/v4:lib-support-v4"),
|
||||||
],
|
],
|
||||||
|
required_for_source_only_abi = True,
|
||||||
visibility = [
|
visibility = [
|
||||||
"PUBLIC",
|
"PUBLIC",
|
||||||
],
|
],
|
||||||
|
|
|
@ -16,6 +16,7 @@ android_library(
|
||||||
provided_deps = [
|
provided_deps = [
|
||||||
react_native_dep("third-party/android/support/v4:lib-support-v4"),
|
react_native_dep("third-party/android/support/v4:lib-support-v4"),
|
||||||
],
|
],
|
||||||
|
required_for_source_only_abi = True,
|
||||||
visibility = [
|
visibility = [
|
||||||
"PUBLIC",
|
"PUBLIC",
|
||||||
],
|
],
|
||||||
|
|
|
@ -9,17 +9,14 @@
|
||||||
|
|
||||||
package com.facebook.react.devsupport;
|
package com.facebook.react.devsupport;
|
||||||
|
|
||||||
import javax.annotation.Nullable;
|
import android.os.Handler;
|
||||||
|
import android.os.Looper;
|
||||||
|
import com.facebook.infer.annotation.Assertions;
|
||||||
|
import com.facebook.react.bridge.JavaJSExecutor;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.concurrent.Semaphore;
|
import java.util.concurrent.Semaphore;
|
||||||
import java.util.concurrent.atomic.AtomicInteger;
|
import java.util.concurrent.atomic.AtomicInteger;
|
||||||
|
import javax.annotation.Nullable;
|
||||||
import android.os.Handler;
|
|
||||||
import android.os.Looper;
|
|
||||||
|
|
||||||
import com.facebook.infer.annotation.Assertions;
|
|
||||||
import com.facebook.react.bridge.JavaJSExecutor;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Executes JS remotely via the react nodejs server as a proxy to a browser on the host machine.
|
* Executes JS remotely via the react nodejs server as a proxy to a browser on the host machine.
|
||||||
|
@ -160,8 +157,7 @@ public class WebsocketJavaScriptExecutor implements JavaJSExecutor {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void loadApplicationScript(String sourceURL)
|
public void loadApplicationScript(String sourceURL) throws JavaJSExecutor.ProxyExecutorException {
|
||||||
throws ProxyExecutorException {
|
|
||||||
JSExecutorCallbackFuture callback = new JSExecutorCallbackFuture();
|
JSExecutorCallbackFuture callback = new JSExecutorCallbackFuture();
|
||||||
Assertions.assertNotNull(mWebSocketClient).loadApplicationScript(
|
Assertions.assertNotNull(mWebSocketClient).loadApplicationScript(
|
||||||
sourceURL,
|
sourceURL,
|
||||||
|
@ -176,7 +172,7 @@ public class WebsocketJavaScriptExecutor implements JavaJSExecutor {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public @Nullable String executeJSCall(String methodName, String jsonArgsArray)
|
public @Nullable String executeJSCall(String methodName, String jsonArgsArray)
|
||||||
throws ProxyExecutorException {
|
throws JavaJSExecutor.ProxyExecutorException {
|
||||||
JSExecutorCallbackFuture callback = new JSExecutorCallbackFuture();
|
JSExecutorCallbackFuture callback = new JSExecutorCallbackFuture();
|
||||||
Assertions.assertNotNull(mWebSocketClient).executeJSCall(
|
Assertions.assertNotNull(mWebSocketClient).executeJSCall(
|
||||||
methodName,
|
methodName,
|
||||||
|
|
|
@ -3,6 +3,7 @@ include_defs("//ReactAndroid/DEFS")
|
||||||
android_library(
|
android_library(
|
||||||
name = "annotations",
|
name = "annotations",
|
||||||
srcs = glob(["**/*.java"]),
|
srcs = glob(["**/*.java"]),
|
||||||
|
required_for_source_only_abi = True,
|
||||||
visibility = [
|
visibility = [
|
||||||
"PUBLIC",
|
"PUBLIC",
|
||||||
],
|
],
|
||||||
|
|
|
@ -14,6 +14,7 @@ android_library(
|
||||||
provided_deps = [
|
provided_deps = [
|
||||||
react_native_dep("third-party/android/support/v4:lib-support-v4"),
|
react_native_dep("third-party/android/support/v4:lib-support-v4"),
|
||||||
],
|
],
|
||||||
|
required_for_source_only_abi = True,
|
||||||
visibility = [
|
visibility = [
|
||||||
"PUBLIC",
|
"PUBLIC",
|
||||||
],
|
],
|
||||||
|
|
|
@ -3,6 +3,7 @@ include_defs("//ReactAndroid/DEFS")
|
||||||
android_library(
|
android_library(
|
||||||
name = "annotations",
|
name = "annotations",
|
||||||
srcs = glob(["*.java"]),
|
srcs = glob(["*.java"]),
|
||||||
|
required_for_source_only_abi = True,
|
||||||
visibility = [
|
visibility = [
|
||||||
"PUBLIC",
|
"PUBLIC",
|
||||||
],
|
],
|
||||||
|
|
|
@ -12,7 +12,7 @@ import android.view.animation.Transformation;
|
||||||
*/
|
*/
|
||||||
/* package */ class OpacityAnimation extends Animation {
|
/* package */ class OpacityAnimation extends Animation {
|
||||||
|
|
||||||
static class OpacityAnimationListener implements AnimationListener {
|
static class OpacityAnimationListener implements Animation.AnimationListener {
|
||||||
|
|
||||||
private final View mView;
|
private final View mView;
|
||||||
private boolean mLayerTypeChanged = false;
|
private boolean mLayerTypeChanged = false;
|
||||||
|
|
|
@ -11,6 +11,7 @@ android_library(
|
||||||
react_native_dep("third-party/android/support-annotations:android-support-annotations"),
|
react_native_dep("third-party/android/support-annotations:android-support-annotations"),
|
||||||
react_native_dep("third-party/android/support/v4:lib-support-v4"),
|
react_native_dep("third-party/android/support/v4:lib-support-v4"),
|
||||||
],
|
],
|
||||||
|
required_for_source_only_abi = True,
|
||||||
visibility = ["PUBLIC"],
|
visibility = ["PUBLIC"],
|
||||||
deps = [
|
deps = [
|
||||||
react_native_dep("third-party/java/jsr-305:jsr-305"),
|
react_native_dep("third-party/java/jsr-305:jsr-305"),
|
||||||
|
|
|
@ -54,13 +54,13 @@ public class ReactViewGroup extends ViewGroup implements
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This listener will be set for child views when removeClippedSubview property is enabled. When
|
* This listener will be set for child views when removeClippedSubview property is enabled. When
|
||||||
* children layout is updated, it will call {@link #updateSubviewClipStatus} to notify parent
|
* children layout is updated, it will call {@link #updateSubviewClipStatus} to notify parent view
|
||||||
* view about that fact so that view can be attached/detached if necessary.
|
* about that fact so that view can be attached/detached if necessary.
|
||||||
*
|
*
|
||||||
* TODO(7728005): Attach/detach views in batch - once per frame in case when multiple children
|
* <p>TODO(7728005): Attach/detach views in batch - once per frame in case when multiple children
|
||||||
* update their layout.
|
* update their layout.
|
||||||
*/
|
*/
|
||||||
private static final class ChildrenLayoutChangeListener implements OnLayoutChangeListener {
|
private static final class ChildrenLayoutChangeListener implements View.OnLayoutChangeListener {
|
||||||
|
|
||||||
private final ReactViewGroup mParent;
|
private final ReactViewGroup mParent;
|
||||||
|
|
||||||
|
@ -396,7 +396,7 @@ public class ReactViewGroup extends ViewGroup implements
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void addView(View child, int index, LayoutParams params) {
|
public void addView(View child, int index, ViewGroup.LayoutParams params) {
|
||||||
// This will get called for every overload of addView so there is not need to override every method.
|
// This will get called for every overload of addView so there is not need to override every method.
|
||||||
mDrawingOrderHelper.handleAddView(child);
|
mDrawingOrderHelper.handleAddView(child);
|
||||||
setChildrenDrawingOrderEnabled(mDrawingOrderHelper.shouldEnableCustomDrawingOrder());
|
setChildrenDrawingOrderEnabled(mDrawingOrderHelper.shouldEnableCustomDrawingOrder());
|
||||||
|
@ -468,7 +468,8 @@ public class ReactViewGroup extends ViewGroup implements
|
||||||
addViewWithSubviewClippingEnabled(child, index, sDefaultLayoutParam);
|
addViewWithSubviewClippingEnabled(child, index, sDefaultLayoutParam);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*package*/ void addViewWithSubviewClippingEnabled(View child, int index, LayoutParams params) {
|
/*package*/ void addViewWithSubviewClippingEnabled(
|
||||||
|
View child, int index, ViewGroup.LayoutParams params) {
|
||||||
Assertions.assertCondition(mRemoveClippedSubviews);
|
Assertions.assertCondition(mRemoveClippedSubviews);
|
||||||
Assertions.assertNotNull(mClippingRect);
|
Assertions.assertNotNull(mClippingRect);
|
||||||
Assertions.assertNotNull(mAllChildren);
|
Assertions.assertNotNull(mAllChildren);
|
||||||
|
|
|
@ -9,19 +9,17 @@
|
||||||
|
|
||||||
package com.facebook.react.views.viewpager;
|
package com.facebook.react.views.viewpager;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import android.support.v4.view.PagerAdapter;
|
import android.support.v4.view.PagerAdapter;
|
||||||
import android.support.v4.view.ViewPager;
|
import android.support.v4.view.ViewPager;
|
||||||
import android.view.MotionEvent;
|
import android.view.MotionEvent;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
import com.facebook.react.bridge.ReactContext;
|
import com.facebook.react.bridge.ReactContext;
|
||||||
import com.facebook.react.uimanager.UIManagerModule;
|
import com.facebook.react.uimanager.UIManagerModule;
|
||||||
import com.facebook.react.uimanager.events.EventDispatcher;
|
import com.facebook.react.uimanager.events.EventDispatcher;
|
||||||
import com.facebook.react.uimanager.events.NativeGestureUtil;
|
import com.facebook.react.uimanager.events.NativeGestureUtil;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Wrapper view for {@link ViewPager}. It's forwarding calls to {@link ViewGroup#addView} to add
|
* Wrapper view for {@link ViewPager}. It's forwarding calls to {@link ViewGroup#addView} to add
|
||||||
|
@ -118,7 +116,7 @@ public class ReactViewPager extends ViewPager {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private class PageChangeListener implements OnPageChangeListener {
|
private class PageChangeListener implements ViewPager.OnPageChangeListener {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) {
|
public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) {
|
||||||
|
|
Loading…
Reference in New Issue