Fix double counting of margins in keygaurd status bar view
The margin for the status icons was moved to the outer container, but KeyguardStatusBarView was still putting the margin manually on the system icon container. This CL removes that extra padding Test: check keyguard status icon container size in web-hv Bug: 228928266 Change-Id: I5dd557c5506296532dc7bfb16930ec1b20b0ffdd
This commit is contained in:
@@ -233,9 +233,6 @@ public class KeyguardStatusBarView extends RelativeLayout {
|
||||
LinearLayout.LayoutParams lp =
|
||||
(LinearLayout.LayoutParams) mSystemIconsContainer.getLayoutParams();
|
||||
|
||||
int marginStart = getResources().getDimensionPixelSize(
|
||||
R.dimen.system_icons_super_container_margin_start);
|
||||
|
||||
// Use status_bar_padding_end to replace original
|
||||
// system_icons_super_container_avatarless_margin_end to prevent different end alignment
|
||||
// between PhoneStatusBarView and KeyguardStatusBarView
|
||||
@@ -248,8 +245,7 @@ public class KeyguardStatusBarView extends RelativeLayout {
|
||||
// 1. status bar layout: mPadding(consider round_corner + privacy dot)
|
||||
// 2. icon container: R.dimen.status_bar_padding_end
|
||||
|
||||
if (marginEnd != lp.getMarginEnd() || marginStart != lp.getMarginStart()) {
|
||||
lp.setMarginStart(marginStart);
|
||||
if (marginEnd != lp.getMarginEnd()) {
|
||||
lp.setMarginEnd(marginEnd);
|
||||
mSystemIconsContainer.setLayoutParams(lp);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user