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

Commit e4503659 authored by Joey's avatar Joey
Browse files

ExactCalculator: support dark mode



Works with StylesAPI

Change-Id: I8b2fa37e84baaae2fe390e897c494a1aa90e590f
Signed-off-by: default avatarJoey <joey@lineageos.org>
parent 64ba4338
Loading
Loading
Loading
Loading
+29 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  Copyright (C) 2018 The LineageOS 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:height="24dp"
    android:width="24dp"
    android:viewportHeight="24"
    android:viewportWidth="24">
    <path
        android:fillColor="@color/pad_button_text_color"
        android:pathData="M19,15.59L17.59,17L14,13.41L10.41,17L9,15.59L12.59,12L9,8.41
        L10.41,7L14,10.59L17.59,7L19,8.41L15.41,12L19,15.59M22,3A2,2 0 0,1 24,5V19A2,2 0 0,1 22,21
        H7C6.31,21 5.77,20.64 5.41,20.11L0,12L5.41,3.88C5.77,3.35 6.31,3 7,3H22M22,5
        H7L2.28,12L7,19H22V5Z" />
</vector>
+1 −1
Original line number Diff line number Diff line
@@ -32,7 +32,7 @@
        android:navigationContentDescription="@string/desc_navigate_up"
        android:navigationIcon="?android:attr/homeAsUpIndicator"
        android:popupTheme="@android:style/ThemeOverlay.Material.Light"
        android:theme="@android:style/ThemeOverlay.Material.Dark.ActionBar"
        android:theme="@style/Theme.Toolbar"
        android:title="@string/title_history" />

    <androidx.recyclerview.widget.RecyclerView
+3 −3
Original line number Diff line number Diff line
@@ -24,11 +24,11 @@
    app:rowCount="5"
    app:columnCount="1">

    <Button
    <ImageButton
        android:id="@+id/del"
        style="@style/PadButtonStyle.Operator.Text"
        style="@style/PadButtonStyle.Operator"
        android:contentDescription="@string/desc_del"
        android:text="@string/del"
        android:src="@drawable/ic_del"
        app:layout_row="0"
        app:layout_column="0" />

+3 −3
Original line number Diff line number Diff line
@@ -32,11 +32,11 @@
        app:layout_row="0"
        app:layout_column="0" />

    <Button
    <ImageButton
        android:id="@+id/del"
        style="@style/PadButtonStyle.Operator.Text"
        style="@style/PadButtonStyle.Operator"
        android:contentDescription="@string/desc_del"
        android:text="@string/del"
        android:src="@drawable/ic_del"
        app:layout_row="0"
        app:layout_column="1" />

+42 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  Copyright (C) 2018 The LineageOS 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.
  -->

<resources>
    <!-- Primary color (Color for the toolbars). -->
    <color name="calculator_primary_color">#212121</color>

    <!-- Status bar color. -->
    <color name="calculator_statusbar_color">#000000</color>

    <!-- Background color for the operator pad. -->
    <color name="pad_operator_background_color">#1E1E1E</color>

    <!-- Text color for the formula in the calculator display. -->
    <color name="display_formula_text_color">@android:color/white</color>

    <!-- Text color for the result in the calculator display. -->
    <color name="display_result_text_color">#6CFFFFFF</color>

    <!-- Lighter color for exponent while scrolling. -->
    <color name="display_result_exponent_text_color">#40FFFFFF</color>

    <!-- Text color for a button in a pad. -->
    <color name="pad_button_text_color">@android:color/white</color>

    <!-- Ripple color when a button is pressed in a pad. -->
    <color name="pad_button_ripple_color">#33FFFFFF</color>
</resources>
Loading