|
2 | 2 |
|
3 | 3 | import android.content.Context;
|
4 | 4 | import android.graphics.Color;
|
5 |
| -import android.os.Build; |
6 |
| -import androidx.annotation.NonNull; |
7 |
| -import androidx.annotation.Nullable; |
8 | 5 | import android.view.LayoutInflater;
|
9 | 6 | import android.view.View;
|
10 | 7 | import android.view.ViewGroup;
|
|
18 | 15 | import java.util.List;
|
19 | 16 | import java.util.Locale;
|
20 | 17 |
|
| 18 | +import androidx.annotation.NonNull; |
| 19 | +import androidx.annotation.Nullable; |
21 | 20 | import butterknife.BindView;
|
22 | 21 | import butterknife.ButterKnife;
|
23 | 22 | import fr.free.nrw.commons.R;
|
@@ -126,16 +125,14 @@ public void init(int position, boolean isDropDownView) {
|
126 | 125 | view.setVisibility(View.VISIBLE);
|
127 | 126 | if (languageCodesList.get(position).isEmpty()) {
|
128 | 127 | tvLanguage.setText(languageNamesList.get(position));
|
129 |
| - tvLanguage.setTextColor(Color.GRAY); |
130 | 128 | tvLanguage.setTextAlignment(View.TEXT_ALIGNMENT_CENTER);
|
131 | 129 | } else {
|
132 | 130 | tvLanguage.setText(
|
133 | 131 | String.format("%s [%s]", languageNamesList.get(position), languageCodesList.get(position)));
|
134 | 132 | if(selectedLanguages.containsKey(languageCodesList.get(position))&&
|
135 |
| - !languageCodesList.get(position).equals(selectedLangCode)) |
| 133 | + !languageCodesList.get(position).equals(selectedLangCode)) { |
136 | 134 | tvLanguage.setTextColor(Color.GRAY);
|
137 |
| - else |
138 |
| - tvLanguage.setTextColor(Color.BLACK); |
| 135 | + } |
139 | 136 | }
|
140 | 137 | }
|
141 | 138 | }
|
|
0 commit comments