You've already forked android_translation_layer
mirror of
https://gitlab.com/android_translation_layer/android_translation_layer.git
synced 2025-10-27 11:48:10 -07:00
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.
This commit is contained in:
@@ -1400,10 +1400,10 @@ public class View implements Drawable.Callback {
|
|||||||
|
|
||||||
public final void measure(int widthMeasureSpec, int heightMeasureSpec) {
|
public final void measure(int widthMeasureSpec, int heightMeasureSpec) {
|
||||||
if (layoutRequested || widthMeasureSpec != oldWidthMeasureSpec || heightMeasureSpec != oldHeightMeasureSpec) {
|
if (layoutRequested || widthMeasureSpec != oldWidthMeasureSpec || heightMeasureSpec != oldHeightMeasureSpec) {
|
||||||
|
layoutRequested = false;
|
||||||
oldWidthMeasureSpec = widthMeasureSpec;
|
oldWidthMeasureSpec = widthMeasureSpec;
|
||||||
oldHeightMeasureSpec = heightMeasureSpec;
|
oldHeightMeasureSpec = heightMeasureSpec;
|
||||||
onMeasure(widthMeasureSpec, heightMeasureSpec);
|
onMeasure(widthMeasureSpec, heightMeasureSpec);
|
||||||
layoutRequested = false;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user