1
0
mirror of https://github.com/KokaKiwi/BarInsta synced 2024-12-23 05:16:58 +00:00

make media shares look better

This commit is contained in:
Austin Huang 2021-06-28 17:04:20 -04:00
parent b4b91c68e3
commit 37663ced30
No known key found for this signature in database
GPG Key ID: 84C23AA04587A91F
2 changed files with 1 additions and 32 deletions

View File

@ -65,7 +65,6 @@ public class DirectItemMediaShareViewHolder extends DirectItemViewHolder {
if (media == null) return;
itemView.post(() -> {
setupUser(media);
setupTitle(media);
setupCaption(media);
});
final int index;
@ -140,16 +139,6 @@ public class DirectItemMediaShareViewHolder extends DirectItemViewHolder {
}
}
private void setupTitle(@NonNull final Media media) {
final String title = media.getTitle();
if (!TextUtils.isEmpty(title)) {
binding.title.setVisibility(View.VISIBLE);
binding.title.setText(title);
} else {
binding.title.setVisibility(View.GONE);
}
}
private void setupUser(@NonNull final Media media) {
final User user = media.getUser();
if (user != null) {

View File

@ -76,26 +76,7 @@
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@id/title" />
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/title"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:paddingStart="8dp"
android:paddingTop="8dp"
android:paddingEnd="8dp"
android:paddingBottom="0dp"
android:textAppearance="@style/TextAppearance.MaterialComponents.Body2"
android:textColor="@color/white"
android:textStyle="bold"
app:layout_constraintBottom_toTopOf="@id/caption"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="1"
app:layout_constraintVertical_chainStyle="packed"
tools:text="Title" />
app:layout_constraintTop_toTopOf="@id/caption" />
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/caption"
@ -107,6 +88,5 @@
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/title"
tools:text="Caption Caption Caption Caption Caption Caption " />
</androidx.constraintlayout.widget.ConstraintLayout>