From f208e944d286905287da811369e7b07efad2c2d8 Mon Sep 17 00:00:00 2001 From: Julian Winkler Date: Fri, 10 Oct 2025 12:02:47 +0200 Subject: [PATCH] View: respect requestLayout() calls also from inside onMeasure() Previously, we accidentally cleared the flag after onMeasure(). This fixes one cause for the bug where you had to resize the window to see the content, but the bug still persists in some apps like Shosetsu. --- src/api-impl/android/view/View.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api-impl/android/view/View.java b/src/api-impl/android/view/View.java index 3b2b1496..a6a7e303 100644 --- a/src/api-impl/android/view/View.java +++ b/src/api-impl/android/view/View.java @@ -1400,10 +1400,10 @@ public class View implements Drawable.Callback { public final void measure(int widthMeasureSpec, int heightMeasureSpec) { if (layoutRequested || widthMeasureSpec != oldWidthMeasureSpec || heightMeasureSpec != oldHeightMeasureSpec) { + layoutRequested = false; oldWidthMeasureSpec = widthMeasureSpec; oldHeightMeasureSpec = heightMeasureSpec; onMeasure(widthMeasureSpec, heightMeasureSpec); - layoutRequested = false; } }