summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/settings/light-and-power/light.cpp2
-rw-r--r--core/settings/light-and-power/lightsettingsbase.ui63
2 files changed, 39 insertions, 26 deletions
diff --git a/core/settings/light-and-power/light.cpp b/core/settings/light-and-power/light.cpp
index 24e1fab..960a165 100644
--- a/core/settings/light-and-power/light.cpp
+++ b/core/settings/light-and-power/light.cpp
@@ -67,8 +67,9 @@ LightSettings::LightSettings( QWidget* parent, const char* name, WFlags fl )
67 interval_suspend->setValue( interval ); 67 interval_suspend->setValue( interval );
68 68
69 screensaver_dim->setChecked( config.readNumEntry("Dim",1) != 0 ); 69 screensaver_dim->setChecked( config.readNumEntry("Dim",1) != 0 );
70 screensaver_lightoff->setChecked( config.readNumEntry("LightOff",1) != 0 ); 70 screensaver_lightoff->setChecked( config.readNumEntry("LightOff",1) != 0 );
71 LcdOffOnly->setChecked( config.readNumEntry("LcdOffOnly",0) != 0 );
71 int maxbright = qpe_sysBrightnessSteps(); 72 int maxbright = qpe_sysBrightnessSteps();
72 initbright = config.readNumEntry("Brightness",255); 73 initbright = config.readNumEntry("Brightness",255);
73 brightness->setMaxValue( maxbright ); 74 brightness->setMaxValue( maxbright );
74 brightness->setTickInterval( QMAX(1,maxbright/16) ); 75 brightness->setTickInterval( QMAX(1,maxbright/16) );
@@ -112,8 +113,9 @@ void LightSettings::accept()
112 Config config( "qpe" ); 113 Config config( "qpe" );
113 config.setGroup( "Screensaver" ); 114 config.setGroup( "Screensaver" );
114 config.writeEntry( "Dim", (int)screensaver_dim->isChecked() ); 115 config.writeEntry( "Dim", (int)screensaver_dim->isChecked() );
115 config.writeEntry( "LightOff", (int)screensaver_lightoff->isChecked() ); 116 config.writeEntry( "LightOff", (int)screensaver_lightoff->isChecked() );
117 config.writeEntry( "LcdOffOnly", (int)LcdOffOnly->isChecked() );
116 config.writeEntry( "Interval_Dim", interval_dim->value() ); 118 config.writeEntry( "Interval_Dim", interval_dim->value() );
117 config.writeEntry( "Interval_LightOff", interval_lightoff->value() ); 119 config.writeEntry( "Interval_LightOff", interval_lightoff->value() );
118 config.writeEntry( "Interval", interval_suspend->value() ); 120 config.writeEntry( "Interval", interval_suspend->value() );
119 config.writeEntry( "Brightness", 121 config.writeEntry( "Brightness",
diff --git a/core/settings/light-and-power/lightsettingsbase.ui b/core/settings/light-and-power/lightsettingsbase.ui
index 47775f7..f2a4552 100644
--- a/core/settings/light-and-power/lightsettingsbase.ui
+++ b/core/settings/light-and-power/lightsettingsbase.ui
@@ -10,10 +10,10 @@
10 <name>geometry</name> 10 <name>geometry</name>
11 <rect> 11 <rect>
12 <x>0</x> 12 <x>0</x>
13 <y>0</y> 13 <y>0</y>
14 <width>256</width> 14 <width>269</width>
15 <height>316</height> 15 <height>317</height>
16 </rect> 16 </rect>
17 </property> 17 </property>
18 <property stdset="1"> 18 <property stdset="1">
19 <name>caption</name> 19 <name>caption</name>
@@ -64,13 +64,13 @@
64 </property> 64 </property>
65 <grid> 65 <grid>
66 <property stdset="1"> 66 <property stdset="1">
67 <name>margin</name> 67 <name>margin</name>
68 <number>6</number> 68 <number>11</number>
69 </property> 69 </property>
70 <property stdset="1"> 70 <property stdset="1">
71 <name>spacing</name> 71 <name>spacing</name>
72 <number>3</number> 72 <number>6</number>
73 </property> 73 </property>
74 <widget row="1" column="1" > 74 <widget row="1" column="1" >
75 <class>QSpinBox</class> 75 <class>QSpinBox</class>
76 <property stdset="1"> 76 <property stdset="1">
@@ -124,30 +124,8 @@
124 <name>lineStep</name> 124 <name>lineStep</name>
125 <number>15</number> 125 <number>15</number>
126 </property> 126 </property>
127 </widget> 127 </widget>
128 <widget row="1" column="0" >
129 <class>QCheckBox</class>
130 <property stdset="1">
131 <name>name</name>
132 <cstring>screensaver_lightoff</cstring>
133 </property>
134 <property stdset="1">
135 <name>sizePolicy</name>
136 <sizepolicy>
137 <hsizetype>1</hsizetype>
138 <vsizetype>0</vsizetype>
139 </sizepolicy>
140 </property>
141 <property stdset="1">
142 <name>text</name>
143 <string>Light off after</string>
144 </property>
145 <property stdset="1">
146 <name>checked</name>
147 <bool>true</bool>
148 </property>
149 </widget>
150 <widget row="0" column="0" > 128 <widget row="0" column="0" >
151 <class>QCheckBox</class> 129 <class>QCheckBox</class>
152 <property stdset="1"> 130 <property stdset="1">
153 <name>name</name> 131 <name>name</name>
@@ -206,8 +184,41 @@
206 <name>text</name> 184 <name>text</name>
207 <string>Suspend after</string> 185 <string>Suspend after</string>
208 </property> 186 </property>
209 </widget> 187 </widget>
188 <widget row="3" column="0" rowspan="1" colspan="2" >
189 <class>QCheckBox</class>
190 <property stdset="1">
191 <name>name</name>
192 <cstring>LcdOffOnly</cstring>
193 </property>
194 <property stdset="1">
195 <name>text</name>
196 <string>Only deactivate LCD during Suspend</string>
197 </property>
198 </widget>
199 <widget row="1" column="0" >
200 <class>QCheckBox</class>
201 <property stdset="1">
202 <name>name</name>
203 <cstring>screensaver_lightoff</cstring>
204 </property>
205 <property stdset="1">
206 <name>sizePolicy</name>
207 <sizepolicy>
208 <hsizetype>1</hsizetype>
209 <vsizetype>0</vsizetype>
210 </sizepolicy>
211 </property>
212 <property stdset="1">
213 <name>text</name>
214 <string>Light off after</string>
215 </property>
216 <property stdset="1">
217 <name>checked</name>
218 <bool>true</bool>
219 </property>
220 </widget>
210 </grid> 221 </grid>
211 </widget> 222 </widget>
212 <widget> 223 <widget>
213 <class>QLayoutWidget</class> 224 <class>QLayoutWidget</class>