Update JNI interface of GetBounds in PrecomputedText
Bug: 77495049
Test: atest CtsWidgetTestCases:EditTextTest
CtsWidgetTestCases:TextViewFadingEdgeTest
FrameworksCoreTests:TextViewFallbackLineSpacingTest
FrameworksCoreTests:TextViewTest FrameworksCoreTests:TypefaceTest
CtsGraphicsTestCases:TypefaceTest CtsWidgetTestCases:TextViewTest
CtsTextTestCases FrameworksCoreTests:android.text
CtsWidgetTestCases:TextViewPrecomputedTextTest
Change-Id: I54a70a91f6fba90720b702b52ed6ad430e17c87d
diff --git a/core/java/android/text/MeasuredParagraph.java b/core/java/android/text/MeasuredParagraph.java
index 96edfa3..c2c3182 100644
--- a/core/java/android/text/MeasuredParagraph.java
+++ b/core/java/android/text/MeasuredParagraph.java
@@ -303,10 +303,9 @@
*
* This is available only if the MeasuredParagraph is computed with buildForStaticLayout.
*/
- public void getBounds(@NonNull Paint paint, @IntRange(from = 0) int start,
- @IntRange(from = 0) int end, @NonNull Rect bounds) {
- nGetBounds(mNativePtr, mCopiedBuffer, paint.getNativeInstance(), start, end,
- paint.getBidiFlags(), bounds);
+ public void getBounds(@IntRange(from = 0) int start, @IntRange(from = 0) int end,
+ @NonNull Rect bounds) {
+ nGetBounds(mNativePtr, mCopiedBuffer, start, end, bounds);
}
/**
@@ -743,6 +742,6 @@
@CriticalNative
private static native int nGetMemoryUsage(/* Non Zero */ long nativePtr);
- private static native void nGetBounds(long nativePtr, char[] buf, long paintPtr, int start,
- int end, int bidiFlag, Rect rect);
+ private static native void nGetBounds(long nativePtr, char[] buf, int start, int end,
+ Rect rect);
}