Merge "Fix calculation of RelativeLayout width in RTL mode"

This commit is contained in:
TreeHugger Robot
2017-07-14 21:10:57 +00:00
committed by Android (Google) Code Review

View File

@@ -486,7 +486,7 @@ public class RelativeLayout extends ViewGroup {
if (targetSdkVersion < Build.VERSION_CODES.KITKAT) {
width = Math.max(width, myWidth - params.mLeft);
} else {
width = Math.max(width, myWidth - params.mLeft - params.leftMargin);
width = Math.max(width, myWidth - params.mLeft + params.leftMargin);
}
} else {
if (targetSdkVersion < Build.VERSION_CODES.KITKAT) {