Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 55661f22 authored by Cecilia Hong's avatar Cecilia Hong Committed by Automerger Merge Worker
Browse files

Merge "Make the recommendation card's title to be one line, and the blur...

Merge "Make the recommendation card's title to be one line, and the blur overlay for the cutting off text." into sc-qpr1-dev am: 69c0e2b9 am: aba82c26 am: 9048582d

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15847412

Change-Id: Iada350fea4ddd9f838e3e9e27504ae7d8274e761
parents c4a61448 9048582d
Loading
Loading
Loading
Loading
+26 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2021 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.
-->

<shape
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:shape="rectangle">
    <corners android:radius="24dp"/>
    <gradient
        android:angle="0"
        android:startColor="#00000000"
        android:endColor="#ff000000"
        android:type="linear" />
</shape>
+25 −4
Original line number Diff line number Diff line
@@ -48,20 +48,41 @@
        android:id="@+id/recommendation_card_icon"
        android:layout_width="@dimen/qs_media_icon_size"
        android:layout_height="@dimen/qs_media_icon_size"
        android:layout_marginTop="@dimen/qs_media_padding"
        android:src="@drawable/ic_headset"
        style="@style/MediaPlayer.AppIcon"/>
        style="@style/MediaPlayer.AppIcon"
        app:layout_constraintTop_toTopOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintEnd_toStartOf="@id/media_vertical_start_guideline"
        app:layout_constraintHorizontal_bias="0"/>

    <TextView
        android:id="@+id/recommendation_card_text"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:maxLines="2"
        android:maxLines="1"
        android:text="@string/controls_media_smartspace_rec_title"
        android:fontFamily="google-sans-medium"
        android:textDirection="locale"
        android:textSize="@dimen/qq_aa_media_rec_header_text_size"
        android:breakStrategy="balanced"
        android:hyphenationFrequency="none"/>
        android:hyphenationFrequency="none"
        app:layout_constraintTop_toBottomOf="@id/recommendation_card_icon"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintEnd_toStartOf="@id/media_vertical_start_guideline"
        app:layout_constraintHorizontal_bias="0"/>

    <View
        android:id="@+id/recommendation_gradient_view"
        android:layout_width="@dimen/qs_aa_media_gradient_bg_width"
        android:layout_height="0dp"
        android:clipToPadding="false"
        android:clipChildren="false"
        android:background="@drawable/qs_media_recommendation_bg_gradient"
        app:layout_constraintTop_toTopOf="@id/recommendation_card_text"
        app:layout_constraintBottom_toBottomOf="@id/recommendation_card_text"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintEnd_toStartOf="@id/media_vertical_start_guideline"
        app:layout_constraintHorizontal_bias="1"/>

    <FrameLayout
        android:id="@+id/media_cover1_container"
+1 −0
Original line number Diff line number Diff line
@@ -1310,6 +1310,7 @@
    <!-- Size of Smartspace media recommendations cards in the QSPanel carousel -->
    <dimen name="qs_aa_media_rec_album_size_collapsed">72dp</dimen>
    <dimen name="qs_aa_media_rec_album_size_expanded">76dp</dimen>
    <dimen name="qs_aa_media_gradient_bg_width">32dp</dimen>
    <dimen name="qs_aa_media_rec_album_margin">8dp</dimen>
    <dimen name="qs_aa_media_rec_album_margin_vert">4dp</dimen>
    <dimen name="qq_aa_media_rec_header_text_size">16sp</dimen>
+0 −19
Original line number Diff line number Diff line
@@ -18,25 +18,6 @@
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto">

    <Constraint
        android:id="@+id/recommendation_card_icon"
        android:layout_width="@dimen/qs_media_icon_size"
        android:layout_height="@dimen/qs_media_icon_size"
        android:layout_marginTop="@dimen/qs_media_padding"
        app:layout_constraintTop_toTopOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintEnd_toStartOf="@id/media_vertical_start_guideline"
        app:layout_constraintHorizontal_bias="0" />

    <Constraint
        android:id="@+id/recommendation_card_text"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        app:layout_constraintTop_toBottomOf="@id/recommendation_card_icon"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintEnd_toStartOf="@id/media_vertical_start_guideline"
        app:layout_constraintHorizontal_bias="0" />

    <Constraint
        android:id="@+id/media_cover1_container"
        android:layout_width="0dp"
+0 −19
Original line number Diff line number Diff line
@@ -18,25 +18,6 @@
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto">

    <Constraint
        android:id="@+id/recommendation_card_icon"
        android:layout_width="@dimen/qs_media_icon_size"
        android:layout_height="@dimen/qs_media_icon_size"
        android:layout_marginTop="@dimen/qs_media_padding"
        app:layout_constraintTop_toTopOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintEnd_toStartOf="@id/media_vertical_start_guideline"
        app:layout_constraintHorizontal_bias="0" />

    <Constraint
        android:id="@+id/recommendation_card_text"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        app:layout_constraintTop_toBottomOf="@id/recommendation_card_icon"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintEnd_toStartOf="@id/media_vertical_start_guideline"
        app:layout_constraintHorizontal_bias="0" />

    <Constraint
        android:id="@+id/media_cover1_container"
        android:layout_width="0dp"
Loading