make alt badge more transparent

closes sk22#735
This commit is contained in:
sk 2023-07-20 23:19:47 +02:00
parent 8d55f62da9
commit 7a02ca435f
5 changed files with 11 additions and 6 deletions

View File

@ -254,7 +254,7 @@ public class MediaGridStatusDisplayItem extends StatusDisplayItem{
noAltText.setVisibility(!hasAltText && showNoAltIndicator ? View.VISIBLE : View.GONE); noAltText.setVisibility(!hasAltText && showNoAltIndicator ? View.VISIBLE : View.GONE);
altText.setText(att.description); altText.setText(att.description);
altTextWrapper.setVisibility(View.VISIBLE); altTextWrapper.setVisibility(View.VISIBLE);
altTextWrapper.setBackgroundResource(hasAltText ? R.drawable.bg_image_alt_overlay : R.drawable.bg_image_no_alt_overlay); altTextWrapper.setBackgroundResource(hasAltText ? R.drawable.bg_image_alt_text_overlay : R.drawable.bg_image_no_alt_overlay);
altTextWrapper.getViewTreeObserver().addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener(){ altTextWrapper.getViewTreeObserver().addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener(){
@Override @Override
public boolean onPreDraw(){ public boolean onPreDraw(){
@ -365,8 +365,8 @@ public class MediaGridStatusDisplayItem extends StatusDisplayItem{
@Override @Override
public void onAnimationEnd(Animator animation){ public void onAnimationEnd(Animator animation){
altTextAnimator=null; altTextAnimator=null;
altTextWrapper.setVisibility(View.GONE); V.setVisibilityAnimated(altTextWrapper, View.GONE);
btn.setVisibility(View.VISIBLE); V.setVisibilityAnimated(btn, View.VISIBLE);
btn.setAlpha(1); btn.setAlpha(1);
} }
}); });

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"> <shape xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="#B2000000"/> <solid android:color="#69000000"/>
<corners android:radius="4dp"/> <corners android:radius="4dp"/>
</shape> </shape>

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="#D0000000"/>
<corners android:radius="4dp"/>
</shape>

View File

@ -24,7 +24,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="bottom" android:layout_gravity="bottom"
android:textAppearance="@style/m3_label_large" android:textAppearance="@style/m3_label_large"
android:textColor="?colorGray25" android:textColor="?colorM3DarkOnSurface"
android:gravity="center" android:gravity="center"
android:includeFontPadding="false" android:includeFontPadding="false"
android:paddingHorizontal="6dp" android:paddingHorizontal="6dp"

View File

@ -7,7 +7,7 @@
android:layout_gravity="end|bottom" android:layout_gravity="end|bottom"
android:layout_margin="12dp" android:layout_margin="12dp"
android:importantForAccessibility="noHideDescendants" android:importantForAccessibility="noHideDescendants"
android:background="@drawable/bg_image_alt_overlay"> android:background="@drawable/bg_image_alt_text_overlay">
<ImageView <ImageView
android:id="@+id/no_alt_button" android:id="@+id/no_alt_button"