Set item group text color to workaround an Android bug

This commit is contained in:
M66B
2022-01-02 17:18:10 +01:00
parent d97f69e72b
commit 4eff805ef4
4 changed files with 28 additions and 0 deletions

View File

@@ -92,6 +92,9 @@ public class FragmentIdentities extends FragmentBase {
rvIdentity.addItemDecoration(itemDecorator);
}
int textColorSecondary = Helper.resolveColor(getContext(), android.R.attr.textColorSecondary);
int textColorTertiary = Helper.resolveColor(getContext(), android.R.attr.textColorTertiary);
DividerItemDecoration categoryDecorator = new DividerItemDecoration(getContext(), llm.getOrientation()) {
@Override
public void onDraw(@NonNull Canvas canvas, @NonNull RecyclerView parent, @NonNull RecyclerView.State state) {
@@ -143,6 +146,9 @@ public class FragmentIdentities extends FragmentBase {
TextView tvCategory = header.findViewById(R.id.tvCategory);
TextView tvDate = header.findViewById(R.id.tvDate);
tvCategory.setTextColor(textColorSecondary);
tvDate.setTextColor(textColorTertiary);
if (cards) {
View vSeparator = header.findViewById(R.id.vSeparator);
vSeparator.setVisibility(View.GONE);