Loading core/java/android/app/Notification.java +11 −4 Original line number Diff line number Diff line Loading @@ -6197,14 +6197,21 @@ public class Notification implements Parcelable updateExpanderAlignment(contentView, p, hasSecondLine); setHeaderlessVerticalMargins(contentView, p, hasSecondLine); if (notificationsRedesignTemplates() && !p.mHeaderless) { // Update margins to leave space for the top line (but not for headerless views like // HUNS, which use a different layout that already accounts for that). Templates that // have content that will be displayed under the small icon also use a different margin. if (Flags.notificationsRedesignTemplates() && !p.mHeaderless) { // HUNS, which use a different layout that already accounts for that). Templates // that have content that will be displayed under the small icon also use a // different margin. int margin = getContentMarginTop(mContext, R.dimen.notification_2025_content_margin_top); contentView.setViewLayoutMargin(R.id.notification_main_column, RemoteViews.MARGIN_TOP, margin, COMPLEX_UNIT_PX); // Use a slightly larger text margin for expanded text with the redesign int textMarginForLargeIcon = mContext.getResources().getDimensionPixelSize( R.dimen.notification_2025_text_margin_top); contentView.setViewLayoutMargin(p.mTextViewId, RemoteViews.MARGIN_TOP, textMarginForLargeIcon, COMPLEX_UNIT_PX); } return contentView; Loading core/res/res/values/dimens.xml +3 −0 Original line number Diff line number Diff line Loading @@ -663,6 +663,9 @@ <!-- The margin on top of the text of the notification --> <dimen name="notification_text_margin_top">6dp</dimen> <!-- The margin on top of the text of the notification to accommodate the large icon --> <dimen name="notification_2025_text_margin_top">8dp</dimen> <!-- Height of a single line text view in a notification --> <dimen name="notification_text_height">20sp</dimen> Loading core/res/res/values/symbols.xml +1 −0 Original line number Diff line number Diff line Loading @@ -3519,6 +3519,7 @@ <java-symbol type="dimen" name="notification_messaging_spacing_conversation_group" /> <java-symbol type="dimen" name="notification_text_margin_top" /> <java-symbol type="dimen" name="notification_2025_text_margin_top" /> <java-symbol type="dimen" name="notification_inbox_item_top_padding" /> <!-- WallpaperManager config --> Loading Loading
core/java/android/app/Notification.java +11 −4 Original line number Diff line number Diff line Loading @@ -6197,14 +6197,21 @@ public class Notification implements Parcelable updateExpanderAlignment(contentView, p, hasSecondLine); setHeaderlessVerticalMargins(contentView, p, hasSecondLine); if (notificationsRedesignTemplates() && !p.mHeaderless) { // Update margins to leave space for the top line (but not for headerless views like // HUNS, which use a different layout that already accounts for that). Templates that // have content that will be displayed under the small icon also use a different margin. if (Flags.notificationsRedesignTemplates() && !p.mHeaderless) { // HUNS, which use a different layout that already accounts for that). Templates // that have content that will be displayed under the small icon also use a // different margin. int margin = getContentMarginTop(mContext, R.dimen.notification_2025_content_margin_top); contentView.setViewLayoutMargin(R.id.notification_main_column, RemoteViews.MARGIN_TOP, margin, COMPLEX_UNIT_PX); // Use a slightly larger text margin for expanded text with the redesign int textMarginForLargeIcon = mContext.getResources().getDimensionPixelSize( R.dimen.notification_2025_text_margin_top); contentView.setViewLayoutMargin(p.mTextViewId, RemoteViews.MARGIN_TOP, textMarginForLargeIcon, COMPLEX_UNIT_PX); } return contentView; Loading
core/res/res/values/dimens.xml +3 −0 Original line number Diff line number Diff line Loading @@ -663,6 +663,9 @@ <!-- The margin on top of the text of the notification --> <dimen name="notification_text_margin_top">6dp</dimen> <!-- The margin on top of the text of the notification to accommodate the large icon --> <dimen name="notification_2025_text_margin_top">8dp</dimen> <!-- Height of a single line text view in a notification --> <dimen name="notification_text_height">20sp</dimen> Loading
core/res/res/values/symbols.xml +1 −0 Original line number Diff line number Diff line Loading @@ -3519,6 +3519,7 @@ <java-symbol type="dimen" name="notification_messaging_spacing_conversation_group" /> <java-symbol type="dimen" name="notification_text_margin_top" /> <java-symbol type="dimen" name="notification_2025_text_margin_top" /> <java-symbol type="dimen" name="notification_inbox_item_top_padding" /> <!-- WallpaperManager config --> Loading