Make same text and header color at least slightly visible

This commit is contained in:
Sylvia van Os committed 2019-12-16 13:23:16 +01:00
1 parent d24a418beb
commit c0d1b446d1
1 file changed
+3 -1
@@ -7,7 +7,6 @@ import android.graphics.Color;
import android.graphics.drawable.Drawable;
import android.os.Build;
import android.os.Bundle;
import android.support.v4.content.ContextCompat;
import android.support.v4.graphics.ColorUtils;
import android.support.v4.graphics.drawable.DrawableCompat;
import android.support.v4.widget.TextViewCompat;
@@ -200,6 +199,9 @@ public class LoyaltyCardViewActivity extends AppCompatActivity
// Make notification area light if dark icons are needed
window.getDecorView().setSystemUiVisibility(backgroundNeedsDarkIcons ? View.SYSTEM_UI_FLAG_LIGHT_STATUS_BAR : 0);
// Set shadow colour of store text so even same color on same color would be readable
storeName.setShadowLayer(1, 1, 1, backgroundNeedsDarkIcons ? Color.BLACK : Color.WHITE);
if(format != null)
{
findViewById(R.id.barcode).setVisibility(View.VISIBLE);