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

Commit 22d31161 authored by Angela Wang's avatar Angela Wang Committed by Android (Google) Code Review
Browse files

Merge "Disabled state UI of Flash Notifications preview button" into udc-dev

parents 767a923e 53a8cc03
Loading
Loading
Loading
Loading
+64 −0
Original line number Diff line number Diff line
@@ -1581,6 +1581,22 @@
            column="5"/>
    </issue>

    <issue
        id="HardCodedColor"
        severity="Error"
        message="Avoid using hardcoded color"
        category="Correctness"
        priority="4"
        summary="Using hardcoded color"
        explanation="Hardcoded color values are bad because theme changes cannot be uniformly applied.Instead use the theme specific colors such as `?android:attr/textColorPrimary` in attributes.&#xA;This ensures that a theme change from a light to a dark theme can be uniformlyapplied across the app."
        errorLine1="    &lt;color name=&quot;switch_bar_state_disabled_color&quot;>#1FE3E3E3&lt;/color>"
        errorLine2="    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
        <location
            file="res/values-night/colors.xml"
            line="76"
            column="5"/>
    </issue>

    <issue
        id="HardCodedColor"
        severity="Error"
@@ -2957,6 +2973,22 @@
            column="5"/>
    </issue>

    <issue
        id="HardCodedColor"
        severity="Error"
        message="Avoid using hardcoded color"
        category="Correctness"
        priority="4"
        summary="Using hardcoded color"
        explanation="Hardcoded color values are bad because theme changes cannot be uniformly applied.Instead use the theme specific colors such as `?android:attr/textColorPrimary` in attributes.&#xA;This ensures that a theme change from a light to a dark theme can be uniformlyapplied across the app."
        errorLine1="    &lt;color name=&quot;switch_bar_state_disabled_color&quot;>#1F1F1F1F&lt;/color>"
        errorLine2="    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
        <location
            file="res/values/colors.xml"
            line="219"
            column="5"/>
    </issue>

    <issue
        id="HardCodedColor"
        severity="Error"
@@ -6253,6 +6285,38 @@
            column="63"/>
    </issue>

    <issue
        id="HardCodedColor"
        severity="Error"
        message="Avoid using hardcoded color"
        category="Correctness"
        priority="4"
        summary="Using hardcoded color"
        explanation="Hardcoded color values are bad because theme changes cannot be uniformly applied.Instead use the theme specific colors such as `?android:attr/textColorPrimary` in attributes.&#xA;This ensures that a theme change from a light to a dark theme can be uniformlyapplied across the app."
        errorLine1="            &lt;solid android:color=&quot;@color/switch_bar_state_disabled_color&quot;/>"
        errorLine2="                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
        <location
            file="res/drawable/switch_bar_bg_disabled.xml"
            line="22"
            column="20"/>
    </issue>

    <issue
        id="HardCodedColor"
        severity="Error"
        message="Avoid using hardcoded color"
        category="Correctness"
        priority="4"
        summary="Using hardcoded color"
        explanation="Hardcoded color values are bad because theme changes cannot be uniformly applied.Instead use the theme specific colors such as `?android:attr/textColorPrimary` in attributes.&#xA;This ensures that a theme change from a light to a dark theme can be uniformlyapplied across the app."
        errorLine1="            &lt;solid android:color=&quot;@color/switch_bar_state_disabled_color&quot;/>"
        errorLine2="                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
        <location
            file="res/drawable/switch_bar_bg_disabled.xml"
            line="22"
            column="20"/>
    </issue>

    <issue
        id="HardCodedColor"
        severity="Error"
+26 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  Copyright (C) 2023 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:attr/colorControlHighlight">
    <item>
        <shape android:shape="rectangle">
            <solid android:color="@color/switch_bar_state_disabled_color"/>
            <corners android:radius="@dimen/settingslib_switch_bar_radius"/>
        </shape>
    </item>
</ripple>
+1 −0
Original line number Diff line number Diff line
@@ -24,6 +24,7 @@
    android:background="@android:color/transparent">

    <FrameLayout
        android:id="@+id/frame"
        android:layout_height="wrap_content"
        android:layout_width="match_parent"
        android:paddingStart="@dimen/settingslib_switchbar_padding_left"
+3 −0
Original line number Diff line number Diff line
@@ -71,5 +71,8 @@
    <!-- Flash notifications colors -->
    <!-- Screen flash notification color selected stroke in color selection dialog -->
    <color name="screen_flash_color_button_outer_circle_stroke_color">#FFFFFF</color>

    <!-- Switch bar disabled state color-->
    <color name="switch_bar_state_disabled_color">#1FE3E3E3</color>
</resources>
+3 −0
Original line number Diff line number Diff line
@@ -214,4 +214,7 @@
    <color name="screen_flash_preset_opacity_color_10">#4DFF017E</color> <!-- 30% Rose -->
    <color name="screen_flash_preset_opacity_color_11">#4DFF00FE</color> <!-- 30% Magenta -->
    <color name="screen_flash_preset_opacity_color_12">#667F00FF</color> <!-- 40% Violet -->

    <!-- Switch bar disabled state color-->
    <color name="switch_bar_state_disabled_color">#1F1F1F1F</color>
</resources>
Loading