Fix wrong measurement in DecorView
am: ffd049027f
* commit 'ffd049027f1cb85c67353abefcf130c1474c261a':
Fix wrong measurement in DecorView
This commit is contained in:
@@ -585,14 +585,14 @@ public class DecorView extends FrameLayout implements RootViewSurfaceTaker, Wind
|
||||
w = 0;
|
||||
}
|
||||
if (DEBUG_MEASURE) Log.d(mLogTag, "Fixed width: " + w);
|
||||
final int widthSize = MeasureSpec.getSize(widthMeasureSpec);
|
||||
if (w > 0) {
|
||||
final int widthSize = MeasureSpec.getSize(widthMeasureSpec);
|
||||
widthMeasureSpec = MeasureSpec.makeMeasureSpec(
|
||||
Math.min(w, widthSize), EXACTLY);
|
||||
fixedWidth = true;
|
||||
} else {
|
||||
widthMeasureSpec = MeasureSpec.makeMeasureSpec(
|
||||
widthMeasureSpec - mFloatingInsets.left - mFloatingInsets.right,
|
||||
widthSize - mFloatingInsets.left - mFloatingInsets.right,
|
||||
AT_MOST);
|
||||
mApplyFloatingHorizontalInsets = true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user