4a85b729381d5dd80b4bec65d9dfdb008fbbe8eb
[feedingit] / psa_harmattan / feedingit / qml / SettingsPage.qml
1 import QtQuick 1.0
2 import com.nokia.meego 1.0
3
4 Page {
5     id: settingsPage
6     anchors.margins: UiConstants.DefaultMargin
7     anchors.fill: parent
8
9     Column {
10         width: parent.width
11
12         SwitchSetting {
13             text: qsTr("Use Dark Theme")
14             checked: controller.getBooleanSetting("theme")
15
16             onSwitched: {
17                 controller.setBooleanSetting("theme", checked)
18                 theme.inverted = checked
19             }
20         }
21
22         SwitchSetting {
23             text: qsTr("Hide Read Feeds")
24             checked: controller.getBooleanSetting("hideReadFeeds")
25
26             onSwitched: {
27                 controller.setBooleanSetting("hideReadFeeds", checked)
28                 settings.hideReadFeeds = checked
29             }
30         }
31
32         SwitchSetting {
33             text: qsTr("Hide Read Articles")
34             checked: controller.getBooleanSetting("hideReadArticles")
35
36             onSwitched: {
37                 controller.setBooleanSetting("hideReadArticles", checked)
38                 settings.hideReadArticles = checked
39             }
40         }
41
42         SwitchSetting {
43             text: qsTr("Cache Images")
44             checked: controller.getBooleanSetting("imageCache")
45
46             onSwitched: {
47                 controller.setBooleanSetting("imageCache", checked)
48             }
49         }
50
51         SwitchSetting {
52             text: qsTr("Auto-update every 6 hours (requires application running)")
53             checked: controller.getBooleanSetting("autoupdate")
54
55             onSwitched: {
56                 controller.setBooleanSetting("autoupdate", checked)
57                 settings.autoUpdateEnabled = checked
58             }
59         }
60     }
61
62 }