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

Commit eedebc48 authored by Jakub Adamek's avatar Jakub Adamek
Browse files

Adding customizable background colour support.

Also changes how sub-styles are created: copies the modified properties
like e.g. fullscreen from Material. Previously most sub-styles
inherited from their material counterparts and updated just some colors.
The new approach should be more stable wrt changes in device default
theme. It would need updating when Material is updated but these kind
of properties does not look like it would be updated often.

Bug: 31459804
Change-Id: I78862bf33ca3dac586ad0a25f17bf8c0008a1dd0
parent c03d9483
Loading
Loading
Loading
Loading
+20 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2016 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.
-->

<selector xmlns:android="http://schemas.android.com/apk/res/android">
    <item android:state_accelerated="false" android:color="?attr/colorBackground" />
    <item android:color="@android:color/transparent" />
</selector>
+2 −2
Original line number Diff line number Diff line
@@ -32,12 +32,12 @@ easier.
 -->
<resources>
    <!-- Theme used for the intent picker activity. -->
    <style name="Theme.DeviceDefault.Resolver" parent="Theme.Material">
    <style name="Theme.DeviceDefault.Resolver" parent="Theme.DeviceDefault">
        <item name="colorControlActivated">?attr/colorControlHighlight</item>
        <item name="listPreferredItemPaddingStart">?attr/dialogPreferredPadding</item>
        <item name="listPreferredItemPaddingEnd">?attr/dialogPreferredPadding</item>
    </style>

    <!-- Use a dark theme for watches. -->
    <style name="Theme.DeviceDefault.System" parent="Theme.Material" />
    <style name="Theme.DeviceDefault.System" />
</resources>
+7 −0
Original line number Diff line number Diff line
@@ -32,4 +32,11 @@
    <color name="accent_device_default_light">@color/accent_material_light</color>
    <color name="accent_device_default_dark">@color/accent_material_dark</color>
    <color name="accent_device_default_50">@color/material_deep_teal_50</color>

    <color name="background_device_default_dark">@color/background_material_dark</color>
    <color name="background_device_default_light">@color/background_material_light</color>
    <color name="background_floating_device_default_dark">@color/background_floating_material_dark</color>
    <color name="background_floating_device_default_light">@color/background_floating_material_light</color>
    <color name="button_normal_device_default_dark">@color/btn_default_material_dark</color>
    <color name="button_normal_device_default_light">@color/btn_default_material_light</color>
</resources>
+128 −138

File changed.

Preview size limit exceeded, changes collapsed.