[SQUASH]Cherish:Status bar weather [2/2]
@hungphan2001:Bring to Android 11 Signed-off-by: Hưng Phan <phandinhhungvp2001@gmail.com>
This commit is contained in:
24
res/drawable/ic_sb_weather_icon.xml
Normal file
24
res/drawable/ic_sb_weather_icon.xml
Normal file
@@ -0,0 +1,24 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
Copyright (C) 2017 crDroid Android 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:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path android:fillColor="?android:attr/colorControlNormal"
|
||||
android:pathData="M22 17C22.5 17 23 17.5 23 18V22C23 22.5 22.5 23 22 23H17C16.5 23 16 22.5 16 22V18C16 17.5 16.5 17 17 17V15.5C17 14.1 18.1 13 19.5 13C20.9 13 22 14.1 22 15.5V17M21 17V15.5C21 14.7 20.3 14 19.5 14C18.7 14 18 14.7 18 15.5V17H21M19.36 9.03C21.95 9.22 24 11.36 24 14L23.94 14.77C23.59 12.63 21.74 11 19.5 11C17 11 15 13 15 15.5L15 15.76C14.39 16.31 14 17.11 14 18V19H6C2.69 19 0 16.31 0 13C0 9.9 2.34 7.36 5.35 7.04C6.6 4.64 9.11 3 12 3C15.64 3 18.67 5.59 19.36 9.03Z" />
|
||||
</vector>
|
||||
24
res/drawable/ic_sb_weather_icon_nav.xml
Normal file
24
res/drawable/ic_sb_weather_icon_nav.xml
Normal file
@@ -0,0 +1,24 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
Copyright (C) 2017 crDroid Android 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:width="80dp"
|
||||
android:height="80dp"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path android:fillColor="?android:attr/colorControlNormal"
|
||||
android:pathData="M22 17C22.5 17 23 17.5 23 18V22C23 22.5 22.5 23 22 23H17C16.5 23 16 22.5 16 22V18C16 17.5 16.5 17 17 17V15.5C17 14.1 18.1 13 19.5 13C20.9 13 22 14.1 22 15.5V17M21 17V15.5C21 14.7 20.3 14 19.5 14C18.7 14 18 14.7 18 15.5V17H21M19.36 9.03C21.95 9.22 24 11.36 24 14L23.94 14.77C23.59 12.63 21.74 11 19.5 11C17 11 15 13 15 15.5L15 15.76C14.39 16.31 14 17.11 14 18V19H6C2.69 19 0 16.31 0 13C0 9.9 2.34 7.36 5.35 7.04C6.6 4.64 9.11 3 12 3C15.64 3 18.67 5.59 19.36 9.03Z" />
|
||||
</vector>
|
||||
@@ -1322,4 +1322,33 @@
|
||||
<item>9</item>
|
||||
<item>10</item>
|
||||
</string-array>
|
||||
|
||||
<!-- StatusBar weather settings -->
|
||||
<string-array name="status_bar_weather_entries" translatable="false">
|
||||
<item>@string/status_bar_weather_hidden</item>
|
||||
<item>@string/status_bar_temperature_image_show_scale</item>
|
||||
<item>@string/status_bar_temperature_image_hide_scale</item>
|
||||
<item>@string/status_bar_temperature_show_scale_hide_image</item>
|
||||
<item>@string/status_bar_temperature_hide_scale_hide_image</item>
|
||||
<item>@string/status_bar_show_image</item>
|
||||
</string-array>
|
||||
|
||||
<string-array name="status_bar_weather_values" translatable="false">
|
||||
<item>0</item>
|
||||
<item>1</item>
|
||||
<item>2</item>
|
||||
<item>3</item>
|
||||
<item>4</item>
|
||||
<item>5</item>
|
||||
</string-array>
|
||||
|
||||
<string-array name="weather_entries" translatable="false">
|
||||
<item>@string/network_traffic_location_statusbar</item>
|
||||
<item>@string/network_traffic_location_quick_statusbar</item>
|
||||
</string-array>
|
||||
|
||||
<string-array name="weather_values" translatable="false">
|
||||
<item>0</item>
|
||||
<item>1</item>
|
||||
</string-array>
|
||||
</resources>
|
||||
|
||||
@@ -1272,4 +1272,19 @@
|
||||
<!-- Lockscreen blur -->
|
||||
<string name="lockscreen_blur_title">Background blur</string>
|
||||
<string name="lockscreen_blur_disabled">Lock screen Blur cannot be enabled because your current lock screen wallpaper does not match your home screen one, or your device does not support Blur at all.</string>
|
||||
|
||||
<!-- StatusBar weather settings -->
|
||||
<string name="statusbar_weather_title">Status bar weather</string>
|
||||
<string name="statusbar_weather_summary">Configure from QS settings/Weather.</string>
|
||||
<string name="statusbar_weather_dialog_title">Status bar weather style</string>
|
||||
<string name="status_bar_weather_hidden">Hidde weather</string>
|
||||
<string name="status_bar_temperature_image_show_scale">Show temp with scale and image</string>
|
||||
<string name="status_bar_temperature_image_hide_scale">Show temp with image without scale</string>
|
||||
<string name="status_bar_temperature_show_scale_hide_image">Show temp with scale</string>
|
||||
<string name="status_bar_temperature_hide_scale_hide_image">Show temp without scale</string>
|
||||
<string name="status_bar_weather_location_title">Location</string>
|
||||
<string name="status_bar_show_image">Show image</string>
|
||||
<string name="network_traffic_location_disable">Disabled</string>
|
||||
<string name="network_traffic_location_statusbar">Statusbar</string>
|
||||
<string name="network_traffic_location_quick_statusbar">Quick Statusbar</string>
|
||||
</resources>
|
||||
|
||||
@@ -39,6 +39,23 @@
|
||||
android:summary="@string/clock_style_category_summary"
|
||||
android:fragment="com.cherish.settings.fragments.ClockSettings" />
|
||||
|
||||
<ListPreference
|
||||
android:key="status_bar_weather"
|
||||
android:title="@string/statusbar_weather_title"
|
||||
android:dialogTitle="@string/statusbar_weather_dialog_title"
|
||||
android:entries="@array/status_bar_weather_entries"
|
||||
android:icon="@drawable/ic_sb_weather_icon"
|
||||
android:entryValues="@array/status_bar_weather_values" />
|
||||
|
||||
<com.cherish.settings.preferences.SystemSettingListPreference
|
||||
android:key="status_bar_show_weather_location"
|
||||
android:icon="@drawable/ic_sb_weather_icon_nav"
|
||||
android:title="@string/status_bar_weather_location_title"
|
||||
android:entries="@array/weather_entries"
|
||||
android:entryValues="@array/weather_values"
|
||||
android:summary="%s"
|
||||
android:defaultValue="0" />
|
||||
|
||||
<Preference
|
||||
android:title="@string/statusbar_items_title"
|
||||
android:icon="@drawable/ic_shortcuts">
|
||||
|
||||
Reference in New Issue
Block a user