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

Commit 4fdd2c26 authored by Kevin Chyn's avatar Kevin Chyn Committed by Android (Google) Code Review
Browse files

Merge "Use seekbar for cancelling RDM" into main

parents 9f8d79e2 103011d0
Loading
Loading
Loading
Loading
+29 −0
Original line number Diff line number Diff line
<!--
     Copyright (C) 2025 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.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
    android:width="24dp"
    android:height="24dp"
    android:tint="?android:attr/colorControlNormal"
    android:viewportHeight="960"
    android:viewportWidth="960">
    <group
        android:translateX="-0"
        android:translateY="960">
        <path
            android:fillColor="?android:attr/colorPrimary"
            android:pathData="M200 -120q-33 0 -56.5 -23.5T120 -200v-160h80v160h560v-560H200v160h-80v-160q0 -33 23.5 -56.5T200 -840h560q33 0 56.5 23.5T840 -760v560q0 33 -23.5 56.5T760 -120H200Zm220 -160l-56 -58 102 -102H120v-80h346L364 -622l56 -58 200 200 -200 200Z" />
    </group>
</vector>
 No newline at end of file
+32 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?><!--
  ~ Copyright (C) 2025 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
  ~ 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.
  -->

<!-- SeekBar drawable for the rear display cancellation slider. -->
<layer-list xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"
    android:paddingMode="stack">
    <item android:gravity="center"
        android:height="2dp"
        android:width="@dimen/rear_display_progress_width">
        <shape android:shape="rectangle">
            <solid android:color="@androidprv:color/materialColorSurfaceContainer" />
        </shape>
    </item>
    <item
        android:id="@android:id/progress"
        android:gravity="center_vertical|fill_horizontal">
        <com.android.systemui.util.RoundedCornerProgressDrawable android:drawable="@drawable/rear_display_dialog_seekbar_progress" />
    </item>
</layer-list>
 No newline at end of file
+40 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2025 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
  ~ 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.
  -->

<!-- SeekBar drawable for volume rows. This contains a background layer (with a solid round rect,
     and a bottom-aligned icon) and a progress layer (with an accent-colored round rect and icon)
     that moves up and down with the progress value. -->
<layer-list xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"
    android:autoMirrored="true">
    <item android:id="@+id/rear_display_dialog_progress_solid">
        <shape>
            <size android:height="@dimen/rear_display_dialog_slider_height" />
            <solid android:color="?android:attr/colorAccent" />
            <corners android:radius="@dimen/rear_display_dialog_slider_corner_radius"/>
        </shape>
    </item>
    <item
        android:id="@+id/rear_display_dialog_seekbar_progress_icon"
        android:gravity="center_vertical|right"
        android:height="@dimen/rounded_slider_icon_size"
        android:width="@dimen/rounded_slider_icon_size"
        android:right="@dimen/rear_display_dialog_slider_icon_inset">
        <com.android.systemui.util.AlphaTintDrawableWrapper
            android:drawable="@drawable/ic_rear_display_slider"
            android:tint="?androidprv:attr/colorAccentPrimaryVariant" />
    </item>
</layer-list>
 No newline at end of file
+17 −19
Original line number Diff line number Diff line
@@ -52,27 +52,25 @@
        android:text="@string/rear_display_unfolded_front_screen_on"
        android:textAppearance="@style/TextAppearance.Dialog.Title"
        android:lineSpacingExtra="2sp"
        android:translationY="-1.24sp"
        android:paddingBottom="@dimen/rear_display_title_bottom_padding"
        android:gravity="center_horizontal" />

    <!-- Buttons -->
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:orientation="horizontal"
        android:layout_marginTop="36dp">
        <Space
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="1"/>
    <TextView
            android:id="@+id/button_cancel"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
            android:layout_weight="0"
            android:layout_gravity="start"
            android:text="@string/cancel"
            style="@style/Widget.Dialog.Button.BorderButton" />
    </LinearLayout>
        android:text="@string/rear_display_unfolded_front_screen_on_slide_to_cancel"
        android:textAppearance="@style/TextAppearance.Dialog.Body"
        android:lineSpacingExtra="2sp"
        android:paddingBottom="@dimen/rear_display_title_bottom_padding"
        android:gravity="center_horizontal" />

    <SeekBar
        android:id="@+id/seekbar"
        android:layout_width="@dimen/rear_display_animation_width_opened"
        android:layout_height="wrap_content"
        android:progressDrawable="@drawable/rear_display_dialog_seekbar"
        android:thumb="@null"
        android:background="@null"
        android:gravity="center_horizontal" />

</LinearLayout>
+10 −0
Original line number Diff line number Diff line
@@ -2159,4 +2159,14 @@
    <!-- Gradient color wallpaper start -->
    <dimen name="gradient_color_wallpaper_center_offset">128dp</dimen>
    <!-- Gradient color wallpaper end -->

    <!-- Rear display mode -->
    <dimen name="rear_display_dialog_slider_height">42dp</dimen>
    <dimen name="rear_display_dialog_slider_corner_radius">21dp</dimen>
    <!-- (rear_display_dialog_slider_height - rounded_slider_icon_size) / 2 -->
    <dimen name="rear_display_dialog_slider_icon_inset">11dp</dimen>
    <!-- rear_display_animation_width_opened - 2 * rear_display_dialog_slider_corner_radius -->
    <dimen name="rear_display_progress_width">231dp</dimen>
    <!-- Rear display mode end -->

</resources>
Loading