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

Commit ef3c4cfc authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Update ActionButtonsPreference style" into sc-dev am: 77f3b08b am: 5b7fe216

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

Change-Id: Ia88ae3ff3310ca5cb9c64aac38d732cd01c0f691
parents 39d72fac 5b7fe216
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -23,4 +23,15 @@
            column="15"/>
    </issue>

    <issue
        id="NewApi"
        message="`?android:attr/dialogCornerRadius` requires API level 28 (current min is 21)"
        errorLine1="        android:radius=&quot;?android:attr/dialogCornerRadius&quot;"
        errorLine2="              ~~~~~~~~~~~~~~~~~~~~~~~~~~~">
        <location
            file="frameworks/base/packages/SettingsLib/ActionButtonsPreference/res/drawable/settingslib_rounded_background.xml"
            line="23"
            column="9"/>
    </issue>

</issues>
+25 −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"
       xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"
       android:shape="rectangle">
    <solid android:color="?androidprv:attr/colorSurface" />
    <corners
        android:radius="?android:attr/dialogCornerRadius"
    />
</shape>
 No newline at end of file
+78 −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.
  -->

<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:layout_margin="8dp"
    android:paddingHorizontal="8dp"
    android:orientation="horizontal"
    android:background="@drawable/settingslib_rounded_background">

    <Button
        android:id="@+id/button1"
        style="@style/SettingsLibActionButton"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"/>

    <View
        android:id="@+id/divider1"
        android:layout_width="1dp"
        android:layout_height="match_parent"
        android:paddingHorizontal="4dp"
        android:visibility="gone"
        android:background="?android:colorBackground" />

    <Button
        android:id="@+id/button2"
        style="@style/SettingsLibActionButton"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"/>

    <View
        android:id="@+id/divider2"
        android:layout_width="1dp"
        android:layout_height="match_parent"
        android:paddingHorizontal="4dp"
        android:visibility="gone"
        android:background="?android:colorBackground" />

    <Button
        android:id="@+id/button3"
        style="@style/SettingsLibActionButton"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"/>

    <View
        android:id="@+id/divider3"
        android:layout_width="1dp"
        android:layout_height="match_parent"
        android:paddingHorizontal="4dp"
        android:visibility="gone"
        android:background="?android:colorBackground" />

    <Button
        android:id="@+id/button4"
        style="@style/SettingsLibActionButton"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"/>
</LinearLayout>
+5 −5
Original line number Diff line number Diff line
@@ -24,28 +24,28 @@

    <Button
        android:id="@+id/button1"
        style="@style/SettingsActionButton"
        style="@style/SettingsLibActionButton"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"/>

    <Button
        android:id="@+id/button2"
        style="@style/SettingsActionButton"
        style="@style/SettingsLibActionButton"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"/>

    <Button
        android:id="@+id/button3"
        style="@style/SettingsActionButton"
        style="@style/SettingsLibActionButton"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"/>

    <Button
        android:id="@+id/button4"
        style="@style/SettingsActionButton"
        style="@style/SettingsLibActionButton"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"/>
+2 −3
Original line number Diff line number Diff line
@@ -16,10 +16,9 @@
  -->

<resources>
    <style name="SettingsActionButton" parent="android:Widget.DeviceDefault.Button.Borderless.Colored">
    <style name="SettingsLibActionButton" parent="android:Widget.DeviceDefault.Button.Borderless.Colored">
        <item name="android:drawablePadding">4dp</item>
        <item name="android:drawableTint">@*android:color/btn_colored_borderless_text_material</item>
        <item name="android:layout_marginEnd">8dp</item>
        <item name="android:paddingTop">20dp</item>
        <item name="android:paddingBottom">20dp</item>
    </style>
Loading