Loading core/java/com/android/internal/widget/NotificationActionListLayout.java +13 −16 Original line number Diff line number Diff line Loading @@ -50,6 +50,8 @@ public class NotificationActionListLayout extends LinearLayout { private boolean mEmphasizedMode; private int mDefaultPaddingBottom; private int mDefaultPaddingTop; private int mEmphasizedPaddingTop; private int mEmphasizedPaddingBottom; private int mEmphasizedHeight; private int mRegularHeight; @DimenRes private int mCollapsibleIndentDimen = R.dimen.notification_actions_padding_start; Loading Loading @@ -322,12 +324,15 @@ public class NotificationActionListLayout extends LinearLayout { } private void updateHeights() { int paddingTop = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin); int inset = getResources().getDimensionPixelSize( com.android.internal.R.dimen.button_inset_vertical_material); mEmphasizedPaddingTop = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin) - inset; // same padding on bottom and at end int paddingBottom = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin_end); mEmphasizedHeight = paddingBottom + paddingTop + getResources().getDimensionPixelSize( mEmphasizedPaddingBottom = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin_end) - inset; mEmphasizedHeight = mEmphasizedPaddingTop + mEmphasizedPaddingBottom + getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_action_emphasized_height); mRegularHeight = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_action_list_height); Loading Loading @@ -356,18 +361,10 @@ public class NotificationActionListLayout extends LinearLayout { mEmphasizedMode = emphasizedMode; int height; if (emphasizedMode) { int paddingTop = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin); // same padding on bottom and at end int paddingBottom = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin_end); int buttonPaddingInternal = getResources().getDimensionPixelSize( com.android.internal.R.dimen.button_inset_vertical_material); setPaddingRelative(getPaddingStart(), paddingTop - buttonPaddingInternal, mEmphasizedPaddingTop, getPaddingEnd(), paddingBottom - buttonPaddingInternal); mEmphasizedPaddingBottom); setMinimumHeight(mEmphasizedHeight); height = ViewGroup.LayoutParams.WRAP_CONTENT; } else { Loading core/res/res/values/dimens.xml +2 −2 Original line number Diff line number Diff line Loading @@ -257,8 +257,8 @@ <!-- The margin of the notification action list at the top --> <dimen name="notification_action_list_margin_top">0dp</dimen> <!-- The visual height of the emphasized notification action --> <dimen name="notification_action_emphasized_height">36dp</dimen> <!-- The overall height of the emphasized notification action --> <dimen name="notification_action_emphasized_height">48dp</dimen> <!-- The padding of the actions in non-conversation layout. For conversations, the analogous value is calculated in ConversationLayout#updateActionListPadding() --> Loading Loading
core/java/com/android/internal/widget/NotificationActionListLayout.java +13 −16 Original line number Diff line number Diff line Loading @@ -50,6 +50,8 @@ public class NotificationActionListLayout extends LinearLayout { private boolean mEmphasizedMode; private int mDefaultPaddingBottom; private int mDefaultPaddingTop; private int mEmphasizedPaddingTop; private int mEmphasizedPaddingBottom; private int mEmphasizedHeight; private int mRegularHeight; @DimenRes private int mCollapsibleIndentDimen = R.dimen.notification_actions_padding_start; Loading Loading @@ -322,12 +324,15 @@ public class NotificationActionListLayout extends LinearLayout { } private void updateHeights() { int paddingTop = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin); int inset = getResources().getDimensionPixelSize( com.android.internal.R.dimen.button_inset_vertical_material); mEmphasizedPaddingTop = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin) - inset; // same padding on bottom and at end int paddingBottom = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin_end); mEmphasizedHeight = paddingBottom + paddingTop + getResources().getDimensionPixelSize( mEmphasizedPaddingBottom = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin_end) - inset; mEmphasizedHeight = mEmphasizedPaddingTop + mEmphasizedPaddingBottom + getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_action_emphasized_height); mRegularHeight = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_action_list_height); Loading Loading @@ -356,18 +361,10 @@ public class NotificationActionListLayout extends LinearLayout { mEmphasizedMode = emphasizedMode; int height; if (emphasizedMode) { int paddingTop = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin); // same padding on bottom and at end int paddingBottom = getResources().getDimensionPixelSize( com.android.internal.R.dimen.notification_content_margin_end); int buttonPaddingInternal = getResources().getDimensionPixelSize( com.android.internal.R.dimen.button_inset_vertical_material); setPaddingRelative(getPaddingStart(), paddingTop - buttonPaddingInternal, mEmphasizedPaddingTop, getPaddingEnd(), paddingBottom - buttonPaddingInternal); mEmphasizedPaddingBottom); setMinimumHeight(mEmphasizedHeight); height = ViewGroup.LayoutParams.WRAP_CONTENT; } else { Loading
core/res/res/values/dimens.xml +2 −2 Original line number Diff line number Diff line Loading @@ -257,8 +257,8 @@ <!-- The margin of the notification action list at the top --> <dimen name="notification_action_list_margin_top">0dp</dimen> <!-- The visual height of the emphasized notification action --> <dimen name="notification_action_emphasized_height">36dp</dimen> <!-- The overall height of the emphasized notification action --> <dimen name="notification_action_emphasized_height">48dp</dimen> <!-- The padding of the actions in non-conversation layout. For conversations, the analogous value is calculated in ConversationLayout#updateActionListPadding() --> Loading