From 3c647d23e5e00b5663f344b7c3f0ab38d74cf720 Mon Sep 17 00:00:00 2001 From: Philip Milne Date: Tue, 23 Apr 2013 14:31:23 -0700 Subject: Fix for bug 8578258. The fix in: https://googleplex-android-review.googlesource.com/#/c/300346/ worked but the constant used had an extra trailing zero - which was confusing and put a 1 in the 'flag' space of the measurement spec. The intended number was: 0x00800000 Unfortunately, this intended constant doesn't fix this bug. The constant submitted in this fix is: 0x00010000 which is outside the 'flag' space of measurement specs and appears to steer clear of overflow problems in the scenario of this bug. As suggested in the submission above, it would be preferable to rework of the RTL code to avoid the use of such a constant as it seems very unlikely indeed that any choice of integer can avoid problems in all cases. Change-Id: I0c6744257ef2aebe8dbc8c041a447f9b90ee4b84 --- core/java/android/widget/RelativeLayout.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'core/java') diff --git a/core/java/android/widget/RelativeLayout.java b/core/java/android/widget/RelativeLayout.java index 906f02d..f940226 100644 --- a/core/java/android/widget/RelativeLayout.java +++ b/core/java/android/widget/RelativeLayout.java @@ -231,7 +231,7 @@ public class RelativeLayout extends ViewGroup { * {@link View#MEASURED_SIZE_MASK}. * {@link View#MEASURED_STATE_TOO_SMALL}. **/ - private static final int DEFAULT_WIDTH = 0x008000000; + private static final int DEFAULT_WIDTH = 0x00010000; public RelativeLayout(Context context) { super(context); -- cgit v1.1