FabricUIManager

open class FabricUIManager : UIManager, LifecycleEventListener, UIBlockViewResolver, SynchronousEventReceiver

We instruct ProGuard not to strip out any fields or methods, because many of these methods are only called through the JNI from Cxx so it appears that most of this class is "unused".

Constructors

Link copied to clipboard
constructor(@NonNull reactContext: ReactApplicationContext, @NonNull viewManagerRegistry: ViewManagerRegistry, @NonNull batchEventDispatchedListener: BatchEventDispatchedListener)

Properties

Link copied to clipboard
val TAG: String

Functions

Link copied to clipboard
open fun <T : View?> addRootView(rootView: T, initialProps: WritableMap): Int
Registers a new root view.
Link copied to clipboard
open fun addUIBlock(block: UIBlock)
Method added to Fabric for backward compatibility reasons, as users on Paper could call [addUiBlock] and [prependUiBlock] on UIManagerModule.
Link copied to clipboard
Register a UIManagerListener with this UIManager to receive lifecycle callbacks.
Link copied to clipboard
open fun attachRootView(surfaceHandler: SurfaceHandler, rootView: View)
Link copied to clipboard
open fun clearJSResponder()
Clears the JS Responder specified by setJSResponder.
Link copied to clipboard
open fun dispatchCommand(reactTag: Int, commandId: Int, @Nullable commandArgs: ReadableArray)
open fun dispatchCommand(reactTag: Int, commandId: String, @Nullable commandArgs: ReadableArray)
Dispatches the commandId received by parameter to the view associated with the reactTag.
open fun dispatchCommand(surfaceId: Int, reactTag: Int, commandId: Int, @Nullable commandArgs: ReadableArray)
open fun dispatchCommand(surfaceId: Int, reactTag: Int, commandId: String, @Nullable commandArgs: ReadableArray)
Link copied to clipboard
open fun experimental_prefetchResource(componentName: String, surfaceId: Int, reactTag: Int, params: ReadableMapBuffer)
This method initiates preloading of an image specified by ImageSource.
Link copied to clipboard
open fun getColor(surfaceId: Int, resourcePaths: Array<String>): Int
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun getThemeData(surfaceId: Int, defaultTextInputPadding: Array<Float>): Boolean
Link copied to clipboard
open fun initialize()
This method is called after ReactApplicationContext has been created.
Link copied to clipboard
Called before React Native instance is destroyed.
Link copied to clipboard
open fun markActiveTouchForTag(surfaceId: Int, reactTag: Int)
Mark a view as currently active for a touch event.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun onHostDestroy()
Called when host activity receives destroy event (e.g.
Link copied to clipboard
open fun onHostPause()
Called when host activity receives pause event (e.g.
Link copied to clipboard
open fun onHostResume()
Called either when the host activity receives a resume event (e.g.
Link copied to clipboard
Method called when an event has been dispatched on the C++ side.
Link copied to clipboard
open fun prependUIBlock(block: UIBlock)
Method added to Fabric for backward compatibility reasons, as users on Paper could call [addUiBlock] and [prependUiBlock] on UIManagerModule.
Link copied to clipboard
open fun profileNextBatch()
Link copied to clipboard
open fun receiveEvent(reactTag: Int, eventName: String, @Nullable params: WritableMap)
open fun receiveEvent(surfaceId: Int, reactTag: Int, eventName: String, @Nullable params: WritableMap)
This method dispatches events from RN Android code to JS.
open fun receiveEvent(surfaceId: Int, reactTag: Int, eventName: String, canCoalesceEvent: Boolean, @Nullable params: WritableMap, eventCategory: Int)
receiveEvent API that emits an event to C++.
open fun receiveEvent(surfaceId: Int, reactTag: Int, @NonNull eventName: String, canCoalesceEvent: Boolean, @Nullable params: WritableMap, eventCategory: Int, experimentalIsSynchronous: Boolean)
Link copied to clipboard
Unregister a UIManagerListener from this UIManager to stop receiving lifecycle callbacks.
Link copied to clipboard
Resolves Direct Event name exposed to JS from the one known to the Native side.
Link copied to clipboard
open fun resolveView(reactTag: Int): View
Resolves a view based on its reactTag.
Link copied to clipboard
open fun sendAccessibilityEvent(reactTag: Int, eventType: Int)
Dispatch an accessibility event to a view asynchronously.
Link copied to clipboard
open fun sendAccessibilityEventFromJS(surfaceId: Int, reactTag: Int, eventTypeJS: String)
Link copied to clipboard
open fun setJSResponder(surfaceId: Int, reactTag: Int, initialReactTag: Int, blockNativeResponder: Boolean)
Set the JS responder for the view associated with the tags received as a parameter.
Link copied to clipboard
open fun startSurface(surfaceHandler: SurfaceHandler, context: Context, @Nullable rootView: View)

open fun <T : View?> startSurface(rootView: T, moduleName: String, initialProps: WritableMap, widthMeasureSpec: Int, heightMeasureSpec: Int): Int
Registers a new root view with width and height.
Link copied to clipboard
open fun stopSurface(surfaceHandler: SurfaceHandler)

open fun stopSurface(surfaceID: Int)
Stop a surface from running in JS and clears up native memory usage.
Link copied to clipboard
open fun sweepActiveTouchForTag(surfaceId: Int, reactTag: Int)
Sweep a view as currently not active for a touch event.
Link copied to clipboard
Used by native animated module to bypass the process of updating the values through the shadow view hierarchy.
Link copied to clipboard
open fun updateRootLayoutSpecs(surfaceId: Int, widthMeasureSpec: Int, heightMeasureSpec: Int, offsetX: Int, offsetY: Int)
Updates the layout metrics of the root view based on the Measure specs received by parameters.