summaryrefslogtreecommitdiffstats
path: root/res/xml/preferences_weather.xml
blob: 6f7842ed00cf5ced308532e6d516e9ad0888f903 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
<?xml version="1.0" encoding="utf-8"?>

<!-- Copyright (C) 2015 The CyanogenMod Project (DvTonder)

     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.
-->

<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
    android:key="weather_settings"
    android:title="@string/weather_category">

    <PreferenceCategory android:title="@string/general_category">

        <SwitchPreference
            android:key="show_weather"
            android:title="@string/weather_enable"
            android:defaultValue="true" />

        <PreferenceScreen
            android:key="weather_source"
            android:defaultValue=""
            android:summary="@string/weather_source_not_selected"
            android:title="@string/weather_source_title">
            <intent android:action="cyanogenmod.intent.action.MANAGE_WEATHER_PROVIDER_SERVICES" />
        </PreferenceScreen>

        <ListPreference
            android:key="weather_refresh_interval"
            android:dependency="weather_source"
            android:defaultValue="60"
            android:summary="%s"
            android:entries="@array/weather_interval_entries"
            android:entryValues="@array/weather_interval_values"
            android:title="@string/weather_refresh_interval" />

        <SwitchPreference
            android:key="weather_use_custom_location"
            android:dependency="weather_source"
            android:title="@string/weather_use_custom_location"
            android:defaultValue="false" />

        <com.cyanogenmod.lockclock.preference.CustomLocationPreference
            android:key="weather_custom_location_city"
            android:dependency="weather_use_custom_location"
            android:dialogTitle="@string/weather_custom_location_dialog_title"
            android:hint="@string/weather_custom_location_hint"
            android:title="@string/weather_custom_location_title" />
    </PreferenceCategory>

    <PreferenceCategory android:title="@string/display_category">

        <com.cyanogenmod.lockclock.preference.IconSelectionPreference
            android:key="weather_icons"
            android:title="@string/weather_icon_set_title"
            android:dialogTitle="@string/weather_icon_set_title"
            android:dependency="weather_source"
            android:defaultValue="color" />

        <SwitchPreference
            android:key="weather_show_when_minimized"
            android:dependency="weather_source"
            android:title="@string/weather_show_when_minimized_title"
            android:summary="@string/weather_show_when_minimized_summary"
            android:defaultValue="true" />

        <SwitchPreference
            android:key="weather_use_metric"
            android:dependency="weather_source"
            android:title="@string/weather_use_metric" />

        <SwitchPreference
            android:key="weather_show_location"
            android:dependency="weather_source"
            android:title="@string/weather_show_location_title"
            android:defaultValue="true" />

        <SwitchPreference
            android:key="weather_show_timestamp"
            android:dependency="weather_source"
            android:title="@string/weather_show_timestamp_title"
            android:defaultValue="true" />

        <SwitchPreference
            android:key="weather_invert_lowhigh"
            android:dependency="weather_source"
            android:title="@string/weather_invert_lowhigh"
            android:defaultValue="false" />

        <ListPreference
            android:key="weather_font_color"
            android:title="@string/font_color"
            android:dependency="weather_source"
            android:defaultValue="#ffffffff"
            android:entries="@array/font_color_entries"
            android:entryValues="@array/font_color_values" />

        <ListPreference
            android:key="weather_timestamp_font_color"
            android:title="@string/font_color_timestamp"
            android:dependency="weather_source"
            android:defaultValue="#80ffffff"
            android:entries="@array/font_color_entries"
            android:entryValues="@array/font_color_values" />
    </PreferenceCategory>
</PreferenceScreen>