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

Commit 647f9e61 authored by Priyank Singh's avatar Priyank Singh
Browse files

Changes to notification shade.

1. Clip the shade with the glass pane
2. Add handle bar to bottom
3. Change the background color to #DD0000

Bug: 132908271
Test: Manual
Change-Id: I577ec7132d9ad37e951e07c6f1ce3c5a2a814d90
parent 70e0438d
Loading
Loading
Loading
Loading
+26 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
    Copyright (C) 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="@android:color/white">
    <item>
        <shape android:shape="rectangle">
            <corners android:radius="@dimen/clear_all_button_radius"/>
            <solid android:color="@android:color/white"/>
        </shape>
    </item>
</ripple>
 No newline at end of file
+14 −11
Original line number Diff line number Diff line
@@ -26,11 +26,11 @@
        android:id="@+id/glass_pane"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
         app:layout_constraintTop_toTopOf="parent"
        android:translationZ="2dp"
        app:layout_constraintBottom_toBottomOf="parent"
         app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintEnd_toEndOf="parent"
         android:translationZ="2dp"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent"
    />

    <androidx.recyclerview.widget.RecyclerView
@@ -38,9 +38,12 @@
        android:layout_width="0dp"
        android:layout_height="0dp"
        android:orientation="vertical"
        app:layout_constraintTop_toTopOf="parent"
        android:paddingStart="@dimen/notification_shade_list_padding_bottom"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintEnd_toEndOf="parent"/>
        app:layout_constraintTop_toTopOf="parent"/>

    <include layout="@layout/notification_handle_bar"/>

</com.android.car.notification.CarNotificationView>
+30 −0
Original line number Diff line number Diff line
<?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.
*/
-->

<merge xmlns:android="http://schemas.android.com/apk/res/android">
    <View
        android:id="@+id/handle_bar"
        android:layout_width="match_parent"
        android:layout_height="@dimen/notification_shade_handle_bar_height"
        android:layout_marginBottom="@dimen/notification_shade_handle_bar_margin_bottom"
        android:layout_marginEnd="@dimen/notification_shade_handle_bar_margin_start"
        android:layout_marginStart="@dimen/notification_shade_handle_bar_margin_end"
        android:layout_marginTop="@dimen/notification_shade_handle_bar_margin_top"
        android:background="@drawable/notification_handle_bar"/>
</merge>
 No newline at end of file
+1 −1
Original line number Diff line number Diff line
@@ -34,7 +34,7 @@
    <drawable name="system_bar_background">@color/status_bar_background_color</drawable>

    <!-- The background color of the notification shade -->
    <color name="notification_shade_background_color">#99000000</color>
    <color name="notification_shade_background_color">#DD000000</color>

    <!-- The color of the dividing line between grouped notifications. -->
    <color name="notification_divider_color">@*android:color/notification_action_list</color>
+10 −0
Original line number Diff line number Diff line
@@ -88,4 +88,14 @@
    <dimen name="car_volume_item_divider_width">1dp</dimen>
    <dimen name="car_volume_item_divider_margin_end">@*android:dimen/car_padding_4</dimen>
    <dimen name="car_volume_item_corner_radius">@*android:dimen/car_radius_3</dimen>

    <!-- Car notification shade-->
    <dimen name="notification_shade_handle_bar_height">10dp</dimen>
    <dimen name="notification_shade_handle_bar_radius">20dp</dimen>
    <dimen name="notification_shade_handle_bar_margin_start">500dp</dimen>
    <dimen name="notification_shade_handle_bar_margin_end">500dp</dimen>
    <dimen name="notification_shade_handle_bar_margin_top">20dp</dimen>
    <dimen name="notification_shade_handle_bar_margin_bottom">10dp</dimen>
    <dimen name="notification_shade_list_padding_bottom">0dp</dimen>

</resources>
Loading