mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Cleanup SchedulerDelegate interface
Summary: This diff removes the "isLayoutable" parameter from SchedulerDelegate.schedulerDidRequestPreliminaryViewAllocation. This now can be infered from the shadowView parameter Reviewed By: shergin Differential Revision: D14296481 fbshipit-source-id: b200504f9c2bef41f0a70257f1f5a274fbe97cbb
This commit is contained in:
committed by
Facebook Github Bot
parent
e93522b14b
commit
747d1f7029
@@ -467,10 +467,11 @@ void Binding::setPixelDensity(float pointScaleFactor) {
|
||||
|
||||
void Binding::schedulerDidRequestPreliminaryViewAllocation(
|
||||
const SurfaceId surfaceId,
|
||||
bool isLayoutable,
|
||||
const ShadowView &shadowView) {
|
||||
|
||||
if (isLayoutable) {
|
||||
bool isLayoutableShadowNode = shadowView.layoutMetrics != EmptyLayoutMetrics;
|
||||
|
||||
if (isLayoutableShadowNode) {
|
||||
static auto preallocateView =
|
||||
jni::findClassStatic(UIManagerJavaDescriptor)
|
||||
->getMethod<void(jint, jint, jstring, ReadableMap::javaobject)>("preallocateView");
|
||||
|
||||
@@ -64,7 +64,6 @@ class Binding : public jni::HybridClass<Binding>, public SchedulerDelegate {
|
||||
|
||||
void schedulerDidRequestPreliminaryViewAllocation(
|
||||
const SurfaceId surfaceId,
|
||||
bool isLayoutable,
|
||||
const ShadowView &shadowView);
|
||||
|
||||
void setPixelDensity(float pointScaleFactor);
|
||||
|
||||
Reference in New Issue
Block a user