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

Commit 696bd113 authored by Automerger Merge Worker's avatar Automerger Merge Worker Committed by Android (Google) Code Review
Browse files

Merge "Merge "Change color of seamless chip border" into rvc-dev am:...

Merge "Merge "Change color of seamless chip border" into rvc-dev am: 9de64deb am: a0d0503b am: ece38fc6" into rvc-qpr-dev-plus-aosp
parents 1e34615d 9c77dafb
Loading
Loading
Loading
Loading
+26 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2020 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/media_seamless_border">
    <item android:id="@android:id/background">
        <shape
            android:color="@android:color/transparent">
            <stroke android:width="1dp" android:color="@color/media_seamless_border"/>
            <corners android:radius="24dp"/>
        </shape>
    </item>
</ripple>
 No newline at end of file
+1 −1
Original line number Diff line number Diff line
@@ -94,7 +94,7 @@
        android:id="@+id/media_seamless"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:foreground="@*android:drawable/media_seamless_background"
        android:foreground="@drawable/qs_media_seamless_background"
        android:background="@drawable/qs_media_light_source"
        android:orientation="horizontal"
        android:forceHasOverlappingRendering="false"
+1 −0
Original line number Diff line number Diff line
@@ -248,6 +248,7 @@
    <color name="media_secondary_text">#99ffffff</color> <!-- 60% -->
    <color name="media_seekbar_progress">#c0ffffff</color>
    <color name="media_disabled">#80ffffff</color>
    <color name="media_seamless_border">#26ffffff</color> <!-- 15% -->

    <!-- controls -->
    <color name="control_primary_text">#E6FFFFFF</color>
+0 −9
Original line number Diff line number Diff line
@@ -20,13 +20,10 @@ import android.app.PendingIntent;
import android.content.Context;
import android.content.Intent;
import android.content.res.ColorStateList;
import android.graphics.Color;
import android.graphics.Outline;
import android.graphics.Rect;
import android.graphics.drawable.Drawable;
import android.graphics.drawable.GradientDrawable;
import android.graphics.drawable.Icon;
import android.graphics.drawable.RippleDrawable;
import android.media.session.MediaController;
import android.media.session.MediaSession;
import android.media.session.PlaybackState;
@@ -258,12 +255,6 @@ public class MediaControlPanel {
        ImageView iconView = mViewHolder.getSeamlessIcon();
        TextView deviceName = mViewHolder.getSeamlessText();

        // Update the outline color
        RippleDrawable bkgDrawable = (RippleDrawable) mViewHolder.getSeamless().getForeground();
        GradientDrawable rect = (GradientDrawable) bkgDrawable.getDrawable(0);
        rect.setStroke(2, deviceName.getCurrentTextColor());
        rect.setColor(Color.TRANSPARENT);

        final MediaDeviceData device = data.getDevice();
        final int seamlessId = mViewHolder.getSeamless().getId();
        final int seamlessFallbackId = mViewHolder.getSeamlessFallback().getId();