diff options
author | android-build-team Robot <android-build-team-robot@google.com> | 2020-08-28 23:10:49 +0000 |
---|---|---|
committer | android-build-team Robot <android-build-team-robot@google.com> | 2020-08-28 23:10:49 +0000 |
commit | 7cad82d82ec3e54af0571980111523684155c35d (patch) | |
tree | c31ee00420c4cde01e99cf84dc78a915adae20c8 | |
parent | dc25c408cfeb938f12e250a3f4e7ff0ff17f7565 (diff) | |
parent | 6b233f4e85269b95d55b34e2f3a1c269dba0fbc3 (diff) | |
download | Media-7cad82d82ec3e54af0571980111523684155c35d.tar.gz |
Snap for 6799200 from 6b233f4e85269b95d55b34e2f3a1c269dba0fbc3 to rvc-qpr1-release
Change-Id: I9d150a8e4b63fdb388ca10214510f5e293cbd1d8
-rw-r--r-- | res/drawable/grid_item_background.xml | 26 | ||||
-rw-r--r-- | res/layout/media_browse_grid_icons_item.xml | 28 | ||||
-rw-r--r-- | res/layout/media_browse_grid_item.xml | 30 | ||||
-rw-r--r-- | res/values/dimens.xml | 1 |
4 files changed, 35 insertions, 50 deletions
diff --git a/res/drawable/grid_item_background.xml b/res/drawable/grid_item_background.xml deleted file mode 100644 index 0b57a5c..0000000 --- a/res/drawable/grid_item_background.xml +++ /dev/null @@ -1,26 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- - ~ Copyright 2019 The Android Open Source Project - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<ripple - xmlns:android="http://schemas.android.com/apk/res/android" - android:color="@color/car_card_ripple_background"> - <item android:id="@android:id/mask"> - <shape android:shape="rectangle"> - <solid android:color="@android:color/white"/> - <corners android:radius="@dimen/media_browse_grid_item_background_radius"/> - </shape> - </item> -</ripple>
\ No newline at end of file diff --git a/res/layout/media_browse_grid_icons_item.xml b/res/layout/media_browse_grid_icons_item.xml index 6445c03..7d7cce6 100644 --- a/res/layout/media_browse_grid_icons_item.xml +++ b/res/layout/media_browse_grid_icons_item.xml @@ -17,23 +17,29 @@ <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" - android:id="@+id/container" android:layout_width="match_parent" android:layout_height="wrap_content" - android:focusable="true" - android:clickable="true" - android:foreground="@drawable/grid_item_background" android:padding="@dimen/media_browse_grid_item_padding" android:layout_marginBottom="@dimen/media_browse_grid_item_margin_bottom"> - <ImageView - android:id="@+id/thumbnail" - android:layout_width="@dimen/media_browse_grid_icons_item_art_size" - android:layout_height="@dimen/media_browse_grid_icons_item_art_size" - android:scaleType="centerCrop" + <FrameLayout + android:id="@+id/container" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:clickable="true" + android:focusable="true" + android:foreground="?android:attr/selectableItemBackground" app:layout_constraintTop_toTopOf="parent" app:layout_constraintStart_toStartOf="parent" - app:layout_constraintEnd_toEndOf="parent"/> + app:layout_constraintEnd_toEndOf="parent"> + + <ImageView + android:id="@+id/thumbnail" + android:layout_width="@dimen/media_browse_grid_icons_item_art_size" + android:layout_height="@dimen/media_browse_grid_icons_item_art_size" + android:scaleType="centerCrop"/> + + </FrameLayout> <ImageView android:id="@+id/download_icon_with_title" @@ -69,7 +75,7 @@ android:includeFontPadding="false" android:duplicateParentState="true" app:layout_constraintStart_toEndOf="@+id/explicit_icon_with_title" - app:layout_constraintTop_toBottomOf="@+id/thumbnail" + app:layout_constraintTop_toBottomOf="@+id/container" app:layout_constraintEnd_toEndOf="parent"/> <ImageView diff --git a/res/layout/media_browse_grid_item.xml b/res/layout/media_browse_grid_item.xml index 1a96024..1a98106 100644 --- a/res/layout/media_browse_grid_item.xml +++ b/res/layout/media_browse_grid_item.xml @@ -17,24 +17,30 @@ <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" - android:id="@+id/container" android:layout_width="match_parent" android:layout_height="wrap_content" - android:focusable="true" - android:clickable="true" - android:foreground="@drawable/grid_item_background" android:padding="@dimen/media_browse_grid_item_padding" android:layout_marginBottom="@dimen/media_browse_grid_item_margin_bottom"> - <com.android.car.media.common.FixedRatioImageView - android:id="@+id/thumbnail" + <FrameLayout + android:id="@+id/container" android:layout_width="match_parent" - android:layout_height="0dp" - android:scaleType="centerCrop" - app:aspect_ratio="1" - app:layout_constraintTop_toTopOf="parent" + android:layout_height="wrap_content" + android:clickable="true" + android:focusable="true" + android:foreground="?android:attr/selectableItemBackground" + app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" - app:layout_constraintEnd_toEndOf="parent"/> + app:layout_constraintTop_toTopOf="parent"> + + <com.android.car.media.common.FixedRatioImageView + android:id="@+id/thumbnail" + android:layout_width="match_parent" + android:layout_height="0dp" + android:scaleType="centerCrop" + app:aspect_ratio="1"/> + + </FrameLayout> <ImageView android:id="@+id/download_icon_with_title" @@ -68,7 +74,7 @@ android:includeFontPadding="false" android:duplicateParentState="true" app:layout_constraintStart_toEndOf="@+id/explicit_icon_with_title" - app:layout_constraintTop_toBottomOf="@+id/thumbnail" + app:layout_constraintTop_toBottomOf="@+id/container" app:layout_constraintEnd_toEndOf="parent"/> <ImageView diff --git a/res/values/dimens.xml b/res/values/dimens.xml index dbb6ab8..84d326e 100644 --- a/res/values/dimens.xml +++ b/res/values/dimens.xml @@ -106,7 +106,6 @@ <dimen name="media_browse_grid_item_padding">0dp</dimen> <dimen name="media_browse_grid_item_margin_bottom">@dimen/car_ui_padding_4</dimen> <dimen name="media_browse_grid_item_text_margin_top">@dimen/car_ui_padding_3</dimen> - <dimen name="media_browse_grid_item_background_radius">4dp</dimen> <dimen name="media_browse_grid_icons_item_art_size">76dp</dimen> |