Skip to content

Commit

Permalink
Round corners of image views
Browse files Browse the repository at this point in the history
  • Loading branch information
cemrich committed Sep 19, 2024
1 parent 1487a8e commit c93f756
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
Expand All @@ -25,13 +26,16 @@
android:textAppearance="?textAppearanceHeadlineSmall"
tools:text="Some show title" />

<androidx.appcompat.widget.AppCompatImageView
<com.google.android.material.imageview.ShapeableImageView
android:id="@+id/thumbnail"
android:layout_width="400dp"
android:layout_height="150dp"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/activity_vertical_margin"
android:adjustViewBounds="true"
android:maxHeight="250dp"
android:scaleType="centerCrop"
android:visibility="gone"
app:shapeAppearance="@style/ShapeAppearance.Material3.Corner.Medium"
tools:src="@color/colorAccent"
tools:visibility="visible" />

Expand Down
3 changes: 2 additions & 1 deletion app/src/main/res/layout/mediathek_list_fragment_item.xml
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@
app:layout_constraintStart_toEndOf="@id/subtitle_divider"
app:layout_constraintTop_toTopOf="@id/duration" />

<androidx.appcompat.widget.AppCompatImageView
<com.google.android.material.imageview.ShapeableImageView
android:id="@+id/thumbnail"
android:layout_width="80dp"
android:layout_height="0dp"
Expand All @@ -232,6 +232,7 @@
app:layout_constraintHorizontal_chainStyle="packed"
app:layout_constraintStart_toEndOf="@id/title"
app:layout_constraintTop_toTopOf="parent"
app:shapeAppearance="@style/ShapeAppearance.Material3.Corner.Small"
tools:visibility="visible" />

</androidx.constraintlayout.widget.ConstraintLayout>

0 comments on commit c93f756

Please sign in to comment.