diff options
Diffstat (limited to 'doze/res')
-rw-r--r-- | doze/res/layout/doze.xml | 6 | ||||
-rw-r--r-- | doze/res/layout/switch_bar.xml | 19 | ||||
-rw-r--r-- | doze/res/values-night/colors.xml | 2 | ||||
-rw-r--r-- | doze/res/values/colors.xml | 2 | ||||
-rw-r--r-- | doze/res/values/styles.xml | 15 | ||||
-rw-r--r-- | doze/res/xml/doze_settings.xml | 12 |
6 files changed, 28 insertions, 28 deletions
diff --git a/doze/res/layout/doze.xml b/doze/res/layout/doze.xml index 941cdf6..e9f3c0f 100644 --- a/doze/res/layout/doze.xml +++ b/doze/res/layout/doze.xml @@ -18,9 +18,9 @@ --> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" - android:orientation="vertical" - android:layout_height="match_parent" - android:layout_width="match_parent"> + android:layout_width="match_parent" + android:layout_height="match_parent" + android:orientation="vertical"> <include layout="@layout/switch_bar" /> diff --git a/doze/res/layout/switch_bar.xml b/doze/res/layout/switch_bar.xml index 1bf6f6c..e02f196 100644 --- a/doze/res/layout/switch_bar.xml +++ b/doze/res/layout/switch_bar.xml @@ -19,24 +19,25 @@ android:layout_width="match_parent" android:layout_height="?android:attr/actionBarSize" android:background="@drawable/switchbar_background" - android:paddingStart="16dp" - android:paddingEnd="16dp" android:clickable="true" android:gravity="center" + android:paddingStart="16dp" + android:paddingEnd="16dp" android:theme="@*android:style/ThemeOverlay.DeviceDefault.Accent"> - <TextView android:id="@+id/switch_text" - android:layout_height="wrap_content" + <TextView + android:id="@+id/switch_text" android:layout_width="0dp" - android:layout_weight="1" + android:layout_height="wrap_content" android:layout_gravity="center_vertical" - android:paddingStart="56dp" - android:maxLines="2" + android:layout_weight="1" android:ellipsize="end" + android:maxLines="2" + android:paddingStart="56dp" + android:textAlignment="viewStart" android:textAppearance="@android:style/TextAppearance.Material.Title" android:textColor="?android:attr/textColorPrimaryInverse" - android:textSize="18sp" - android:textAlignment="viewStart" /> + android:textSize="18sp" /> <Switch android:id="@android:id/switch_widget" diff --git a/doze/res/values-night/colors.xml b/doze/res/values-night/colors.xml index 5aa9c8e..6d9d63e 100644 --- a/doze/res/values-night/colors.xml +++ b/doze/res/values-night/colors.xml @@ -15,6 +15,6 @@ --> <resources> - <color name="switchbar_switch_track_tint">#82000000</color> <color name="switchbar_switch_thumb_tint">@android:color/black</color> + <color name="switchbar_switch_track_tint">#82000000</color> </resources> diff --git a/doze/res/values/colors.xml b/doze/res/values/colors.xml index bb85f62..ac4c4c3 100644 --- a/doze/res/values/colors.xml +++ b/doze/res/values/colors.xml @@ -16,6 +16,6 @@ <resources> <color name="switchbar_background_color">@*android:color/material_grey_600</color> - <color name="switchbar_switch_track_tint">#BFFFFFFF</color> <color name="switchbar_switch_thumb_tint">@android:color/white</color> + <color name="switchbar_switch_track_tint">#BFFFFFFF</color> </resources> diff --git a/doze/res/values/styles.xml b/doze/res/values/styles.xml index 314665d..4ee4de4 100644 --- a/doze/res/values/styles.xml +++ b/doze/res/values/styles.xml @@ -6,9 +6,9 @@ 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. @@ -16,6 +16,7 @@ limitations under the License. --> <resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2"> + <style name="Theme.Main" parent="@android:style/Theme.DeviceDefault.Settings"> <item name="dialogPreferenceStyle">@style/Theme.Main.DialogPreferenceStyle</item> <item name="preferenceCategoryStyle">@style/Theme.Main.PreferenceCategoryStyle</item> @@ -25,8 +26,7 @@ <item name="switchPreferenceStyle">@style/Theme.Main.SwitchPreferenceStyle</item> </style> - <style name="Theme.Main.DialogPreferenceStyle" parent="@style/Theme.Main.PreferenceStyle"> - </style> + <style name="Theme.Main.DialogPreferenceStyle" parent="@style/Theme.Main.PreferenceStyle"></style> <style name="Theme.Main.PreferenceCategoryStyle" parent="@*android:style/Preference.DeviceDefault.Category"> <item name="allowDividerAbove">true</item> @@ -55,8 +55,7 @@ <item name="widgetLayout">@*android:layout/preference_widget_switch</item> </style> - <style name="Theme.Main.SwitchBar" parent="@android:style/ThemeOverlay.Material.ActionBar"> - </style> + <style name="Theme.Main.SwitchBar" parent="@android:style/ThemeOverlay.Material.ActionBar"></style> <style name="Theme.Main.SwitchBar.Switch"> <item name="android:trackTint">@color/switchbar_switch_track_tint</item> @@ -65,9 +64,9 @@ <style name="Theme.Main.TextAppearance.CategoryTitle" parent="@*android:style/TextAppearance.DeviceDefault.Body2"> - <item name="android:textAllCaps">true</item> - <item name="android:textSize">11sp</item> <!-- 0.8 Spacing, 0.8/11 = 0.072727273 --> <item name="android:letterSpacing">0.072727273</item> + <item name="android:textAllCaps">true</item> + <item name="android:textSize">11sp</item> </style> </resources> diff --git a/doze/res/xml/doze_settings.xml b/doze/res/xml/doze_settings.xml index 43a3c2d..dd6e19b 100644 --- a/doze/res/xml/doze_settings.xml +++ b/doze/res/xml/doze_settings.xml @@ -21,10 +21,10 @@ android:title="@string/tilt_sensor_title"> <SwitchPreference - android:key="gesture_pick_up" android:defaultValue="false" - android:title="@string/pick_up_gesture_title" + android:key="gesture_pick_up" android:summary="@string/pick_up_gesture_summary" + android:title="@string/pick_up_gesture_title" android:icon="@drawable/ic_pickup" /> </PreferenceCategory> @@ -34,17 +34,17 @@ android:title="@string/proximity_sensor_title"> <SwitchPreference - android:key="gesture_hand_wave" android:defaultValue="false" - android:title="@string/hand_wave_gesture_title" + android:key="gesture_hand_wave" android:summary="@string/hand_wave_gesture_summary" + android:title="@string/hand_wave_gesture_title" android:icon="@drawable/ic_hand" /> <SwitchPreference - android:key="gesture_pocket" android:defaultValue="false" - android:title="@string/pocket_gesture_title" + android:key="gesture_pocket" android:summary="@string/pocket_gesture_summary" + android:title="@string/pocket_gesture_title" android:icon="@drawable/ic_pocket" /> </PreferenceCategory> |