Changed reparentChild method name to reparent.
The native reparentChild was changed to reparent to represent that the
current layer is getting re-parented. Updated the jni and Java code to
reflect that.
Test: Device boots
Change-Id: I390d2efba61c626f2162f75f650700d53ab178a5
diff --git a/core/jni/android_view_SurfaceControl.cpp b/core/jni/android_view_SurfaceControl.cpp
index 33f1c7d..bf8bbf5 100644
--- a/core/jni/android_view_SurfaceControl.cpp
+++ b/core/jni/android_view_SurfaceControl.cpp
@@ -736,13 +736,11 @@
ctrl->reparentChildren(handle);
}
-static void nativeReparentChild(JNIEnv* env, jclass clazz, jlong nativeObject,
- jobject newParentObject, jobject childObject) {
+static void nativeReparent(JNIEnv* env, jclass clazz, jlong nativeObject,
+ jobject newParentObject) {
auto ctrl = reinterpret_cast<SurfaceControl *>(nativeObject);
sp<IBinder> parentHandle = ibinderForJavaObject(env, newParentObject);
- sp<IBinder> childHandle = ibinderForJavaObject(env, childObject);
-
- ctrl->reparentChild(parentHandle, childHandle);
+ ctrl->reparent(parentHandle);
}
static void nativeSeverChildren(JNIEnv* env, jclass clazz, jlong nativeObject) {
@@ -868,8 +866,8 @@
(void*)nativeDeferTransactionUntilSurface },
{"nativeReparentChildren", "(JLandroid/os/IBinder;)V",
(void*)nativeReparentChildren } ,
- {"nativeReparentChild", "(JLandroid/os/IBinder;Landroid/os/IBinder;)V",
- (void*)nativeReparentChild },
+ {"nativeReparent", "(JLandroid/os/IBinder;)V",
+ (void*)nativeReparent },
{"nativeSeverChildren", "(J)V",
(void*)nativeSeverChildren } ,
{"nativeSetOverrideScalingMode", "(JI)V",