Inverting color of divider too (#553)
Inverting color of divider too Co-authored-by: opyale <opyale@noreply.gitea.io> Reviewed-by: 6543 <6543@noreply.codeberg.org>
This commit is contained in:
parent
d0fde4e791
commit
2483968f11
@ -56,6 +56,7 @@ public class ProfileFragment extends Fragment {
|
|||||||
ImageView userAvatarBackground = v.findViewById(R.id.userAvatarBackground);
|
ImageView userAvatarBackground = v.findViewById(R.id.userAvatarBackground);
|
||||||
ImageView userAvatar = v.findViewById(R.id.userAvatar);
|
ImageView userAvatar = v.findViewById(R.id.userAvatar);
|
||||||
TextView userLogin = v.findViewById(R.id.userLogin);
|
TextView userLogin = v.findViewById(R.id.userLogin);
|
||||||
|
View divider = v.findViewById(R.id.divider);
|
||||||
TextView userLanguage = v.findViewById(R.id.userLanguage);
|
TextView userLanguage = v.findViewById(R.id.userLanguage);
|
||||||
ImageView userLanguageIcon = v.findViewById(R.id.userLanguageIcon);
|
ImageView userLanguageIcon = v.findViewById(R.id.userLanguageIcon);
|
||||||
|
|
||||||
@ -82,13 +83,14 @@ public class ProfileFragment extends Fragment {
|
|||||||
@Override
|
@Override
|
||||||
public void onSuccess() {
|
public void onSuccess() {
|
||||||
|
|
||||||
int textColor = new ColorInverter().getImageViewContrastColor(userAvatarBackground);
|
int invertedColor = new ColorInverter().getImageViewContrastColor(userAvatarBackground);
|
||||||
|
|
||||||
userFullName.setTextColor(textColor);
|
userFullName.setTextColor(invertedColor);
|
||||||
userLogin.setTextColor(textColor);
|
divider.setBackgroundColor(invertedColor);
|
||||||
userLanguage.setTextColor(textColor);
|
userLogin.setTextColor(invertedColor);
|
||||||
|
userLanguage.setTextColor(invertedColor);
|
||||||
|
|
||||||
ImageViewCompat.setImageTintList(userLanguageIcon, ColorStateList.valueOf(textColor));
|
ImageViewCompat.setImageTintList(userLanguageIcon, ColorStateList.valueOf(invertedColor));
|
||||||
|
|
||||||
blurView.setupWith(aboutFrame)
|
blurView.setupWith(aboutFrame)
|
||||||
.setBlurAlgorithm(new RenderScriptBlur(ctx))
|
.setBlurAlgorithm(new RenderScriptBlur(ctx))
|
||||||
|
@ -61,6 +61,7 @@
|
|||||||
android:textSize="14sp" />
|
android:textSize="14sp" />
|
||||||
|
|
||||||
<View
|
<View
|
||||||
|
android:id="@+id/divider"
|
||||||
android:layout_width="50dp"
|
android:layout_width="50dp"
|
||||||
android:layout_height="1dp"
|
android:layout_height="1dp"
|
||||||
android:layout_marginBottom="10dp"
|
android:layout_marginBottom="10dp"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user