fix(notifications-banner): fix banner layout
This commit is contained in:
parent
f2030a8c26
commit
a849ced203
|
@ -166,12 +166,6 @@ public class SettingsNotificationsFragment extends BaseSettingsFragment<Void>{
|
||||||
bannerAdapter.setVisible(false);
|
bannerAdapter.setVisible(false);
|
||||||
banner.findViewById(R.id.button2).setVisibility(View.GONE);
|
banner.findViewById(R.id.button2).setVisibility(View.GONE);
|
||||||
banner.findViewById(R.id.title).setVisibility(View.GONE);
|
banner.findViewById(R.id.title).setVisibility(View.GONE);
|
||||||
((RelativeLayout.LayoutParams) bannerText.getLayoutParams())
|
|
||||||
.setMargins(0, V.dp(4), 0, 0);
|
|
||||||
((RelativeLayout.LayoutParams) bannerIcon.getLayoutParams())
|
|
||||||
.addRule(RelativeLayout.CENTER_VERTICAL);
|
|
||||||
RelativeLayout.LayoutParams buttonParams = (RelativeLayout.LayoutParams) bannerButton.getLayoutParams();
|
|
||||||
buttonParams.setMargins(buttonParams.leftMargin, V.dp(-8), buttonParams.rightMargin, V.dp(-12));
|
|
||||||
|
|
||||||
mergeAdapter=new MergeRecyclerAdapter();
|
mergeAdapter=new MergeRecyclerAdapter();
|
||||||
mergeAdapter.addAdapter(bannerAdapter);
|
mergeAdapter.addAdapter(bannerAdapter);
|
||||||
|
|
|
@ -13,23 +13,23 @@
|
||||||
android:id="@+id/icon"
|
android:id="@+id/icon"
|
||||||
android:layout_width="40dp"
|
android:layout_width="40dp"
|
||||||
android:layout_height="40dp"
|
android:layout_height="40dp"
|
||||||
android:layout_marginEnd="24dp"
|
android:layout_marginEnd="16dp"
|
||||||
android:scaleType="center"
|
android:scaleType="center"
|
||||||
android:importantForAccessibility="no"
|
android:importantForAccessibility="no"
|
||||||
android:tint="?colorM3OnPrimaryContainer"
|
android:tint="?colorM3OnPrimaryContainer"
|
||||||
android:background="@drawable/white_circle"
|
android:background="@drawable/white_circle"
|
||||||
android:backgroundTint="?colorM3PrimaryContainer"
|
android:backgroundTint="?colorM3PrimaryContainer"
|
||||||
tools:src="@drawable/ic_fluent_alert_snooze_24_regular"/>
|
tools:src="@drawable/ic_notifications_paused_24px"/>
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/title"
|
android:id="@+id/title"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="24dp"
|
||||||
android:layout_toEndOf="@id/icon"
|
android:layout_toEndOf="@id/icon"
|
||||||
android:layout_marginTop="-2dp"
|
|
||||||
android:layout_marginBottom="2dp"
|
android:layout_marginBottom="2dp"
|
||||||
android:textAppearance="@style/m3_title_medium"
|
android:textAppearance="@style/m3_title_medium"
|
||||||
android:textColor="?colorM3OnSurface"
|
android:textColor="?colorM3OnSurface"
|
||||||
|
android:singleLine="true"
|
||||||
android:gravity="center_vertical"
|
android:gravity="center_vertical"
|
||||||
tools:text="Title"/>
|
tools:text="Title"/>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue