mirror of
https://github.com/facebook/react-native.git
synced 2026-11-18 20:19:07 +00:00
covert RNFeedPackage and it's modules to use @ReactModule and @ReactModuleList
Reviewed By: lexs Differential Revision: D3796860 fbshipit-source-id: d4b5f3635754ef28277b79cb1ea9bab07ba3ea6e
This commit is contained in:
1 parent
6c909ef80d
commit
3d1b79cd15
53 files changed
+219
-134
No files matched your search
@@ -6,13 +6,14 @@ android_library(
|
||||
'*.java',
|
||||
]),
|
||||
deps = [
|
||||
react_native_target('java/com/facebook/react/bridge:bridge'),
|
||||
react_native_target('java/com/facebook/react/modules/core:core'),
|
||||
react_native_target('java/com/facebook/react/uimanager:uimanager'),
|
||||
react_native_target('java/com/facebook/react/uimanager/annotations:annotations'),
|
||||
react_native_dep('third-party/android/support/v4:lib-support-v4'),
|
||||
react_native_dep('third-party/java/infer-annotations:infer-annotations'),
|
||||
react_native_dep('third-party/java/jsr-305:jsr-305'),
|
||||
react_native_dep('third-party/android/support/v4:lib-support-v4'),
|
||||
react_native_target('java/com/facebook/react/bridge:bridge'),
|
||||
react_native_target('java/com/facebook/react/module/annotations:annotations'),
|
||||
react_native_target('java/com/facebook/react/modules/core:core'),
|
||||
react_native_target('java/com/facebook/react/uimanager/annotations:annotations'),
|
||||
react_native_target('java/com/facebook/react/uimanager:uimanager'),
|
||||
],
|
||||
visibility = [
|
||||
'PUBLIC',
|
||||
|
||||
@@ -21,6 +21,7 @@ import com.facebook.react.bridge.ReactContextBaseJavaModule;
|
||||
import com.facebook.react.bridge.ReactMethod;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.bridge.WritableMap;
|
||||
import com.facebook.react.module.annotations.ReactModule;
|
||||
import com.facebook.react.modules.core.DeviceEventManagerModule;
|
||||
import com.facebook.react.uimanager.GuardedChoreographerFrameCallback;
|
||||
import com.facebook.react.uimanager.ReactChoreographer;
|
||||
@@ -70,6 +71,7 @@ import java.util.ArrayList;
|
||||
* isolates us from the problems that may be caused by concurrent updates of animated graph while UI
|
||||
* thread is "executing" the animation loop.
|
||||
*/
|
||||
@ReactModule(name = "NativeAnimatedModule")
|
||||
public class NativeAnimatedModule extends ReactContextBaseJavaModule implements
|
||||
OnBatchCompleteListener, LifecycleEventListener {
|
||||
|
||||
@@ -136,8 +138,8 @@ public class NativeAnimatedModule extends ReactContextBaseJavaModule implements
|
||||
// from the UIManagerModule) doesn't matter as we only enqueue operations for the UI thread to
|
||||
// be executed from here. Thanks to ReactChoreographer all the operations from here are going
|
||||
// to be executed *after* all the operations enqueued by UIManager as the callback type that we
|
||||
// use for ReactChoreographer (CallbackType.NATIVE_ANIMATED_MODULE) is run after callbacks that UIManager
|
||||
// use
|
||||
// use for ReactChoreographer (CallbackType.NATIVE_ANIMATED_MODULE) is run after callbacks that
|
||||
// UIManager uses.
|
||||
ArrayList<UIThreadOperation> operations = mOperations.isEmpty() ? null : mOperations;
|
||||
if (operations != null) {
|
||||
mOperations = new ArrayList<>();
|
||||
|
||||
Reference in new issue
Block a user