-rw-r--r-- | core/settings/light-and-power/light.cpp | 103 | ||||
-rw-r--r-- | core/settings/light-and-power/light.h | 5 | ||||
-rw-r--r-- | core/settings/light-and-power/lightsettingsbase.ui | 128 |
3 files changed, 185 insertions, 51 deletions
diff --git a/core/settings/light-and-power/light.cpp b/core/settings/light-and-power/light.cpp index 21377b7..a58b1c1 100644 --- a/core/settings/light-and-power/light.cpp +++ b/core/settings/light-and-power/light.cpp | |||
@@ -38,29 +38,37 @@ | |||
38 | #include <qcheckbox.h> | 38 | #include <qcheckbox.h> |
39 | #include <qtabwidget.h> | 39 | #include <qtabwidget.h> |
40 | #include <qslider.h> | 40 | #include <qslider.h> |
41 | #include <qtimer.h> | 41 | #include <qtimer.h> |
42 | #include <qspinbox.h> | 42 | #include <qspinbox.h> |
43 | #include <qpushbutton.h> | 43 | #include <qpushbutton.h> |
44 | #include <qgroupbox.h> | ||
44 | 45 | ||
45 | #include <opie/odevice.h> | 46 | #include <opie/odevice.h> |
46 | 47 | ||
47 | #include "sensor.h" | 48 | #include "sensor.h" |
48 | 49 | ||
49 | using namespace Opie; | 50 | using namespace Opie; |
50 | 51 | ||
51 | LightSettings::LightSettings( QWidget* parent, const char* name, WFlags ) | 52 | LightSettings::LightSettings( QWidget* parent, const char* name, WFlags ) |
52 | : LightSettingsBase( parent, name, false, WStyle_ContextHelp ) | 53 | : LightSettingsBase( parent, name, false, WStyle_ContextHelp ) |
53 | { | 54 | { |
54 | m_res = ODevice::inst ( )-> displayBrightnessResolution ( ); | 55 | m_bres = ODevice::inst ( )-> displayBrightnessResolution ( ); |
56 | m_cres = ODevice::inst ( )-> displayContrastResolution ( ); | ||
55 | 57 | ||
56 | if ( !ODevice::inst ( )-> hasLightSensor ( )) { | 58 | if ( !ODevice::inst ( )-> hasLightSensor ( )) { |
57 | auto_brightness-> hide ( ); | 59 | auto_brightness-> hide ( ); |
58 | CalibrateLightSensor-> hide ( ); | 60 | CalibrateLightSensor-> hide ( ); |
59 | auto_brightness_ac_3-> hide ( ); | 61 | auto_brightness_ac-> hide ( ); |
60 | CalibrateLightSensorAC-> hide ( ); | 62 | CalibrateLightSensor_ac-> hide ( ); |
63 | } | ||
64 | if (m_cres) { | ||
65 | GroupLight->setTitle(tr("Backlight & Contrast")); | ||
66 | } else { | ||
67 | contrast->hide(); | ||
68 | contrast_ac->hide(); | ||
61 | } | 69 | } |
62 | 70 | ||
63 | Config config ( "apm" ); | 71 | Config config ( "apm" ); |
64 | config. setGroup ( "Battery" ); | 72 | config. setGroup ( "Battery" ); |
65 | 73 | ||
66 | // battery spinboxes | 74 | // battery spinboxes |
@@ -69,41 +77,59 @@ LightSettings::LightSettings( QWidget* parent, const char* name, WFlags ) | |||
69 | interval_suspend-> setValue ( config. readNumEntry ( "Suspend", 60 )); | 77 | interval_suspend-> setValue ( config. readNumEntry ( "Suspend", 60 )); |
70 | 78 | ||
71 | // battery check and slider | 79 | // battery check and slider |
72 | LcdOffOnly-> setChecked ( config. readBoolEntry ( "LcdOffOnly", false )); | 80 | LcdOffOnly-> setChecked ( config. readBoolEntry ( "LcdOffOnly", false )); |
73 | 81 | ||
74 | int bright = config. readNumEntry ( "Brightness", 127 ); | 82 | int bright = config. readNumEntry ( "Brightness", 127 ); |
75 | brightness-> setMaxValue ( m_res - 1 ); | 83 | int contr = config. readNumEntry ( "Contrast", 127 ); |
76 | brightness-> setTickInterval ( QMAX( 1, m_res / 16 )); | 84 | brightness-> setMaxValue ( m_bres - 1 ); |
77 | brightness-> setLineStep ( QMAX( 1, m_res / 16 )); | 85 | brightness-> setTickInterval ( QMAX( 1, m_bres / 16 )); |
78 | brightness-> setPageStep ( QMAX( 1, m_res / 16 )); | 86 | brightness-> setLineStep ( QMAX( 1, m_bres / 16 )); |
79 | brightness-> setValue (( bright * ( m_res - 1 ) + 127 ) / 255 ); | 87 | brightness-> setPageStep ( QMAX( 1, m_bres / 16 )); |
88 | brightness-> setValue (( bright * ( m_bres - 1 ) + 127 ) / 255 ); | ||
89 | |||
90 | if (m_cres) { | ||
91 | contrast-> setMaxValue ( m_cres - 1 ); | ||
92 | contrast-> setTickInterval ( QMAX( 1, m_cres / 16 )); | ||
93 | contrast-> setLineStep ( QMAX( 1, m_cres / 16 )); | ||
94 | contrast-> setPageStep ( QMAX( 1, m_cres / 16 )); | ||
95 | contrast-> setValue (( contr * ( m_cres - 1 ) + 127 ) / 255 ); | ||
96 | } | ||
80 | 97 | ||
81 | // light sensor | 98 | // light sensor |
82 | auto_brightness-> setChecked ( config. readBoolEntry ( "LightSensor", false )); | 99 | auto_brightness-> setChecked ( config. readBoolEntry ( "LightSensor", false )); |
83 | m_sensordata = config. readListEntry ( "LightSensorData", ';' ); | 100 | m_sensordata = config. readListEntry ( "LightSensorData", ';' ); |
84 | 101 | ||
85 | config. setGroup ( "AC" ); | 102 | config. setGroup ( "AC" ); |
86 | 103 | ||
87 | // ac spinboxes | 104 | // ac spinboxes |
88 | interval_dim_ac_3-> setValue ( config. readNumEntry ( "Dim", 60 )); | 105 | interval_dim_ac-> setValue ( config. readNumEntry ( "Dim", 60 )); |
89 | interval_lightoff_ac_3-> setValue ( config. readNumEntry ( "LightOff", 120 )); | 106 | interval_lightoff_ac-> setValue ( config. readNumEntry ( "LightOff", 120 )); |
90 | interval_suspend_ac_3-> setValue ( config. readNumEntry ( "Suspend", 0 )); | 107 | interval_suspend_ac-> setValue ( config. readNumEntry ( "Suspend", 0 )); |
91 | 108 | ||
92 | // ac check and slider | 109 | // ac check and slider |
93 | LcdOffOnly_2_3-> setChecked ( config. readBoolEntry ( "LcdOffOnly", false )); | 110 | LcdOffOnly_ac-> setChecked ( config. readBoolEntry ( "LcdOffOnly", false )); |
94 | 111 | ||
95 | bright = config. readNumEntry ( "Brightness", 255 ); | 112 | bright = config. readNumEntry ( "Brightness", 255 ); |
96 | brightness_ac_3-> setMaxValue ( m_res - 1 ); | 113 | brightness_ac-> setMaxValue ( m_bres - 1 ); |
97 | brightness_ac_3-> setTickInterval ( QMAX( 1, m_res / 16 )); | 114 | brightness_ac-> setTickInterval ( QMAX( 1, m_bres / 16 )); |
98 | brightness_ac_3-> setLineStep ( QMAX( 1, m_res / 16 )); | 115 | brightness_ac-> setLineStep ( QMAX( 1, m_bres / 16 )); |
99 | brightness_ac_3-> setPageStep ( QMAX( 1, m_res / 16 )); | 116 | brightness_ac-> setPageStep ( QMAX( 1, m_bres / 16 )); |
100 | brightness_ac_3-> setValue (( bright * ( m_res - 1 ) + 127 ) / 255 ); | 117 | brightness_ac-> setValue (( bright * ( m_bres - 1 ) + 127 ) / 255 ); |
118 | |||
119 | if (m_cres) { | ||
120 | contr = config. readNumEntry ( "Contrast", 127); | ||
121 | contrast_ac-> setMaxValue ( m_cres - 1 ); | ||
122 | contrast_ac-> setTickInterval ( QMAX( 1, m_cres / 16 )); | ||
123 | contrast_ac-> setLineStep ( QMAX( 1, m_cres / 16 )); | ||
124 | contrast_ac-> setPageStep ( QMAX( 1, m_cres / 16 )); | ||
125 | contrast_ac-> setValue (( contr * ( m_cres - 1 ) + 127 ) / 255 ); | ||
126 | } | ||
101 | 127 | ||
102 | // light sensor | 128 | // light sensor |
103 | auto_brightness_ac_3-> setChecked ( config. readBoolEntry ( "LightSensor", false )); | 129 | auto_brightness_ac-> setChecked ( config. readBoolEntry ( "LightSensor", false )); |
104 | m_sensordata_ac = config. readListEntry ( "LightSensorData", ';' ); | 130 | m_sensordata_ac = config. readListEntry ( "LightSensorData", ';' ); |
105 | 131 | ||
106 | // advanced settings | 132 | // advanced settings |
107 | config. setGroup ( "Warnings" ); | 133 | config. setGroup ( "Warnings" ); |
108 | warnintervalBox-> setValue ( config. readNumEntry ( "checkinterval", 10000 ) / 1000 ); | 134 | warnintervalBox-> setValue ( config. readNumEntry ( "checkinterval", 10000 ) / 1000 ); |
109 | lowSpinBox-> setValue ( config. readNumEntry ( "powerverylow", 10 ) ); | 135 | lowSpinBox-> setValue ( config. readNumEntry ( "powerverylow", 10 ) ); |
@@ -117,13 +143,17 @@ LightSettings::LightSettings( QWidget* parent, const char* name, WFlags ) | |||
117 | } | 143 | } |
118 | else { | 144 | else { |
119 | tabs-> setCurrentPage ( 1 ); | 145 | tabs-> setCurrentPage ( 1 ); |
120 | } | 146 | } |
121 | 147 | ||
122 | connect ( brightness, SIGNAL( valueChanged ( int )), this, SLOT( setBacklight ( int ))); | 148 | connect ( brightness, SIGNAL( valueChanged ( int )), this, SLOT( setBacklight ( int ))); |
123 | connect ( brightness_ac_3, SIGNAL( valueChanged ( int )), this, SLOT( setBacklight ( int ))); | 149 | connect ( brightness_ac, SIGNAL( valueChanged ( int )), this, SLOT( setBacklight ( int ))); |
150 | if (m_havecontrast) { | ||
151 | connect ( contrast, SIGNAL( valueChanged ( int )), this, SLOT( setContrast ( int ))); | ||
152 | connect ( contrast_ac, SIGNAL( valueChanged ( int )), this, SLOT( setContrast ( int ))); | ||
153 | } | ||
124 | } | 154 | } |
125 | 155 | ||
126 | LightSettings::~LightSettings ( ) | 156 | LightSettings::~LightSettings ( ) |
127 | { | 157 | { |
128 | } | 158 | } |
129 | 159 | ||
@@ -145,55 +175,74 @@ void LightSettings::calibrateSensorAC ( ) | |||
145 | delete s; | 175 | delete s; |
146 | } | 176 | } |
147 | 177 | ||
148 | void LightSettings::setBacklight ( int bright ) | 178 | void LightSettings::setBacklight ( int bright ) |
149 | { | 179 | { |
150 | if ( bright >= 0 ) | 180 | if ( bright >= 0 ) |
151 | bright = bright * 255 / ( m_res - 1 ); | 181 | bright = bright * 255 / ( m_bres - 1 ); |
152 | 182 | ||
153 | QCopEnvelope e ( "QPE/System", "setBacklight(int)" ); | 183 | QCopEnvelope e ( "QPE/System", "setBacklight(int)" ); |
154 | e << bright; | 184 | e << bright; |
155 | 185 | ||
156 | if ( bright != -1 ) { | 186 | if ( bright != -1 ) { |
157 | m_resettimer-> stop ( ); | 187 | m_resettimer-> stop ( ); |
158 | m_resettimer-> start ( 2000, true ); | 188 | m_resettimer-> start ( 2000, true ); |
159 | } | 189 | } |
160 | } | 190 | } |
161 | 191 | ||
192 | void LightSettings::setContrast ( int contr ) | ||
193 | { | ||
194 | if ( contr >= 0 ) | ||
195 | contr = contr * 255 / ( m_cres - 1 ); | ||
196 | |||
197 | QCopEnvelope e ( "QPE/System", "setContrast(int)" ); | ||
198 | e << contr; | ||
199 | |||
200 | if ( contr != -1 ) { | ||
201 | m_resettimer-> stop ( ); | ||
202 | m_resettimer-> start ( 2000, true ); | ||
203 | } | ||
204 | } | ||
205 | |||
162 | void LightSettings::resetBacklight ( ) | 206 | void LightSettings::resetBacklight ( ) |
163 | { | 207 | { |
164 | setBacklight ( -1 ); | 208 | setBacklight ( -1 ); |
209 | setContrast ( -1 ); | ||
165 | } | 210 | } |
166 | 211 | ||
167 | void LightSettings::accept ( ) | 212 | void LightSettings::accept ( ) |
168 | { | 213 | { |
169 | Config config ( "apm" ); | 214 | Config config ( "apm" ); |
170 | 215 | ||
171 | // bat | 216 | // bat |
172 | config. setGroup ( "Battery" ); | 217 | config. setGroup ( "Battery" ); |
173 | config. writeEntry ( "LcdOffOnly", LcdOffOnly-> isChecked ( )); | 218 | config. writeEntry ( "LcdOffOnly", LcdOffOnly-> isChecked ( )); |
174 | config. writeEntry ( "Dim", interval_dim-> value ( )); | 219 | config. writeEntry ( "Dim", interval_dim-> value ( )); |
175 | config. writeEntry ( "LightOff", interval_lightoff-> value ( )); | 220 | config. writeEntry ( "LightOff", interval_lightoff-> value ( )); |
176 | config. writeEntry ( "Suspend", interval_suspend-> value ( )); | 221 | config. writeEntry ( "Suspend", interval_suspend-> value ( )); |
177 | config. writeEntry ( "Brightness", brightness-> value ( ) * 255 / ( m_res - 1 ) ); | 222 | config. writeEntry ( "Brightness", brightness-> value ( ) * 255 / ( m_bres - 1 ) ); |
223 | if (m_cres) | ||
224 | config. writeEntry ( "Contrast", contrast-> value ( ) * 255 / ( m_cres - 1 ) ); | ||
178 | 225 | ||
179 | // ac | 226 | // ac |
180 | config. setGroup ( "AC" ); | 227 | config. setGroup ( "AC" ); |
181 | config. writeEntry ( "LcdOffOnly", LcdOffOnly_2_3-> isChecked ( )); | 228 | config. writeEntry ( "LcdOffOnly", LcdOffOnly_ac-> isChecked ( )); |
182 | config. writeEntry ( "Dim", interval_dim_ac_3-> value ( )); | 229 | config. writeEntry ( "Dim", interval_dim_ac-> value ( )); |
183 | config. writeEntry ( "LightOff", interval_lightoff_ac_3-> value ( )); | 230 | config. writeEntry ( "LightOff", interval_lightoff_ac-> value ( )); |
184 | config. writeEntry ( "Suspend", interval_suspend_ac_3-> value ( )); | 231 | config. writeEntry ( "Suspend", interval_suspend_ac-> value ( )); |
185 | config. writeEntry ( "Brightness", brightness_ac_3-> value ( ) * 255 / ( m_res - 1 )); | 232 | config. writeEntry ( "Brightness", brightness_ac-> value ( ) * 255 / ( m_bres - 1 )); |
233 | if (m_cres) | ||
234 | config. writeEntry ( "Contrast", contrast_ac-> value ( ) * 255 / ( m_cres - 1 )); | ||
186 | 235 | ||
187 | // only make light sensor stuff appear if the unit has a sensor | 236 | // only make light sensor stuff appear if the unit has a sensor |
188 | if ( ODevice::inst ( )-> hasLightSensor ( )) { | 237 | if ( ODevice::inst ( )-> hasLightSensor ( )) { |
189 | config. setGroup ( "Battery" ); | 238 | config. setGroup ( "Battery" ); |
190 | config. writeEntry ( "LightSensor", auto_brightness->isChecked() ); | 239 | config. writeEntry ( "LightSensor", auto_brightness->isChecked() ); |
191 | config. writeEntry ( "LightSensorData", m_sensordata, ';' ); | 240 | config. writeEntry ( "LightSensorData", m_sensordata, ';' ); |
192 | config. setGroup ( "AC" ); | 241 | config. setGroup ( "AC" ); |
193 | config. writeEntry ( "LightSensor", auto_brightness_ac_3->isChecked() ); | 242 | config. writeEntry ( "LightSensor", auto_brightness_ac->isChecked() ); |
194 | config. writeEntry ( "LightSensorData", m_sensordata_ac, ';' ); | 243 | config. writeEntry ( "LightSensorData", m_sensordata_ac, ';' ); |
195 | } | 244 | } |
196 | 245 | ||
197 | // advanced | 246 | // advanced |
198 | config. setGroup ( "Warnings" ); | 247 | config. setGroup ( "Warnings" ); |
199 | config. writeEntry ( "check_interval", warnintervalBox-> value ( ) * 1000 ); | 248 | config. writeEntry ( "check_interval", warnintervalBox-> value ( ) * 1000 ); |
diff --git a/core/settings/light-and-power/light.h b/core/settings/light-and-power/light.h index 0a3c60b..c9757da 100644 --- a/core/settings/light-and-power/light.h +++ b/core/settings/light-and-power/light.h | |||
@@ -47,16 +47,19 @@ protected: | |||
47 | virtual void done ( int r ); | 47 | virtual void done ( int r ); |
48 | 48 | ||
49 | protected slots: | 49 | protected slots: |
50 | virtual void calibrateSensor ( ); | 50 | virtual void calibrateSensor ( ); |
51 | virtual void calibrateSensorAC ( ); | 51 | virtual void calibrateSensorAC ( ); |
52 | void setBacklight ( int ); | 52 | void setBacklight ( int ); |
53 | void setContrast ( int ); | ||
53 | void resetBacklight ( ); | 54 | void resetBacklight ( ); |
54 | 55 | ||
55 | private: | 56 | private: |
56 | int m_res; | 57 | int m_bres; |
58 | int m_cres; | ||
59 | int m_havecontrast; | ||
57 | QTimer *m_resettimer; | 60 | QTimer *m_resettimer; |
58 | QStringList m_sensordata; | 61 | QStringList m_sensordata; |
59 | QStringList m_sensordata_ac; | 62 | QStringList m_sensordata_ac; |
60 | }; | 63 | }; |
61 | 64 | ||
62 | 65 | ||
diff --git a/core/settings/light-and-power/lightsettingsbase.ui b/core/settings/light-and-power/lightsettingsbase.ui index 99bbd71..8fdd604 100644 --- a/core/settings/light-and-power/lightsettingsbase.ui +++ b/core/settings/light-and-power/lightsettingsbase.ui | |||
@@ -8,13 +8,13 @@ | |||
8 | </property> | 8 | </property> |
9 | <property stdset="1"> | 9 | <property stdset="1"> |
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>363</width> | 14 | <width>355</width> |
15 | <height>532</height> | 15 | <height>532</height> |
16 | </rect> | 16 | </rect> |
17 | </property> | 17 | </property> |
18 | <property stdset="1"> | 18 | <property stdset="1"> |
19 | <name>sizePolicy</name> | 19 | <name>sizePolicy</name> |
20 | <sizepolicy> | 20 | <sizepolicy> |
@@ -273,13 +273,13 @@ | |||
273 | </grid> | 273 | </grid> |
274 | </widget> | 274 | </widget> |
275 | <widget> | 275 | <widget> |
276 | <class>QGroupBox</class> | 276 | <class>QGroupBox</class> |
277 | <property stdset="1"> | 277 | <property stdset="1"> |
278 | <name>name</name> | 278 | <name>name</name> |
279 | <cstring>GroupBox9</cstring> | 279 | <cstring>GroupLight</cstring> |
280 | </property> | 280 | </property> |
281 | <property stdset="1"> | 281 | <property stdset="1"> |
282 | <name>title</name> | 282 | <name>title</name> |
283 | <string>Backlight</string> | 283 | <string>Backlight</string> |
284 | </property> | 284 | </property> |
285 | <property> | 285 | <property> |
@@ -288,17 +288,17 @@ | |||
288 | <property> | 288 | <property> |
289 | <name>layoutSpacing</name> | 289 | <name>layoutSpacing</name> |
290 | </property> | 290 | </property> |
291 | <vbox> | 291 | <vbox> |
292 | <property stdset="1"> | 292 | <property stdset="1"> |
293 | <name>margin</name> | 293 | <name>margin</name> |
294 | <number>5</number> | 294 | <number>11</number> |
295 | </property> | 295 | </property> |
296 | <property stdset="1"> | 296 | <property stdset="1"> |
297 | <name>spacing</name> | 297 | <name>spacing</name> |
298 | <number>3</number> | 298 | <number>6</number> |
299 | </property> | 299 | </property> |
300 | <widget> | 300 | <widget> |
301 | <class>QSlider</class> | 301 | <class>QSlider</class> |
302 | <property stdset="1"> | 302 | <property stdset="1"> |
303 | <name>name</name> | 303 | <name>name</name> |
304 | <cstring>brightness</cstring> | 304 | <cstring>brightness</cstring> |
@@ -334,12 +334,51 @@ | |||
334 | <property> | 334 | <property> |
335 | <name>whatsThis</name> | 335 | <name>whatsThis</name> |
336 | <string>set a fix value for backlight</string> | 336 | <string>set a fix value for backlight</string> |
337 | </property> | 337 | </property> |
338 | </widget> | 338 | </widget> |
339 | <widget> | 339 | <widget> |
340 | <class>QSlider</class> | ||
341 | <property stdset="1"> | ||
342 | <name>name</name> | ||
343 | <cstring>contrast</cstring> | ||
344 | </property> | ||
345 | <property stdset="1"> | ||
346 | <name>maxValue</name> | ||
347 | <number>255</number> | ||
348 | </property> | ||
349 | <property stdset="1"> | ||
350 | <name>lineStep</name> | ||
351 | <number>1</number> | ||
352 | </property> | ||
353 | <property stdset="1"> | ||
354 | <name>pageStep</name> | ||
355 | <number>16</number> | ||
356 | </property> | ||
357 | <property stdset="1"> | ||
358 | <name>tracking</name> | ||
359 | <bool>true</bool> | ||
360 | </property> | ||
361 | <property stdset="1"> | ||
362 | <name>orientation</name> | ||
363 | <enum>Horizontal</enum> | ||
364 | </property> | ||
365 | <property stdset="1"> | ||
366 | <name>tickmarks</name> | ||
367 | <enum>Right</enum> | ||
368 | </property> | ||
369 | <property stdset="1"> | ||
370 | <name>tickInterval</name> | ||
371 | <number>32</number> | ||
372 | </property> | ||
373 | <property> | ||
374 | <name>whatsThis</name> | ||
375 | <string>set a fix value for contrast</string> | ||
376 | </property> | ||
377 | </widget> | ||
378 | <widget> | ||
340 | <class>QLayoutWidget</class> | 379 | <class>QLayoutWidget</class> |
341 | <property stdset="1"> | 380 | <property stdset="1"> |
342 | <name>name</name> | 381 | <name>name</name> |
343 | <cstring>Layout10</cstring> | 382 | <cstring>Layout10</cstring> |
344 | </property> | 383 | </property> |
345 | <property> | 384 | <property> |
@@ -553,13 +592,13 @@ | |||
553 | <number>3</number> | 592 | <number>3</number> |
554 | </property> | 593 | </property> |
555 | <widget row="1" column="1" > | 594 | <widget row="1" column="1" > |
556 | <class>QSpinBox</class> | 595 | <class>QSpinBox</class> |
557 | <property stdset="1"> | 596 | <property stdset="1"> |
558 | <name>name</name> | 597 | <name>name</name> |
559 | <cstring>interval_lightoff_ac_3</cstring> | 598 | <cstring>interval_lightoff_ac</cstring> |
560 | </property> | 599 | </property> |
561 | <property stdset="1"> | 600 | <property stdset="1"> |
562 | <name>suffix</name> | 601 | <name>suffix</name> |
563 | <string> sec</string> | 602 | <string> sec</string> |
564 | </property> | 603 | </property> |
565 | <property stdset="1"> | 604 | <property stdset="1"> |
@@ -602,13 +641,13 @@ | |||
602 | </property> | 641 | </property> |
603 | </widget> | 642 | </widget> |
604 | <widget row="2" column="1" > | 643 | <widget row="2" column="1" > |
605 | <class>QSpinBox</class> | 644 | <class>QSpinBox</class> |
606 | <property stdset="1"> | 645 | <property stdset="1"> |
607 | <name>name</name> | 646 | <name>name</name> |
608 | <cstring>interval_suspend_ac_3</cstring> | 647 | <cstring>interval_suspend_ac</cstring> |
609 | </property> | 648 | </property> |
610 | <property stdset="1"> | 649 | <property stdset="1"> |
611 | <name>suffix</name> | 650 | <name>suffix</name> |
612 | <string> sec</string> | 651 | <string> sec</string> |
613 | </property> | 652 | </property> |
614 | <property stdset="1"> | 653 | <property stdset="1"> |
@@ -651,13 +690,13 @@ | |||
651 | </property> | 690 | </property> |
652 | </widget> | 691 | </widget> |
653 | <widget row="0" column="1" > | 692 | <widget row="0" column="1" > |
654 | <class>QSpinBox</class> | 693 | <class>QSpinBox</class> |
655 | <property stdset="1"> | 694 | <property stdset="1"> |
656 | <name>name</name> | 695 | <name>name</name> |
657 | <cstring>interval_dim_ac_3</cstring> | 696 | <cstring>interval_dim_ac</cstring> |
658 | </property> | 697 | </property> |
659 | <property stdset="1"> | 698 | <property stdset="1"> |
660 | <name>suffix</name> | 699 | <name>suffix</name> |
661 | <string> sec</string> | 700 | <string> sec</string> |
662 | </property> | 701 | </property> |
663 | <property stdset="1"> | 702 | <property stdset="1"> |
@@ -700,13 +739,13 @@ | |||
700 | </property> | 739 | </property> |
701 | </widget> | 740 | </widget> |
702 | <widget row="3" column="0" rowspan="1" colspan="2" > | 741 | <widget row="3" column="0" rowspan="1" colspan="2" > |
703 | <class>QCheckBox</class> | 742 | <class>QCheckBox</class> |
704 | <property stdset="1"> | 743 | <property stdset="1"> |
705 | <name>name</name> | 744 | <name>name</name> |
706 | <cstring>LcdOffOnly_2_3</cstring> | 745 | <cstring>LcdOffOnly_ac</cstring> |
707 | </property> | 746 | </property> |
708 | <property stdset="1"> | 747 | <property stdset="1"> |
709 | <name>sizePolicy</name> | 748 | <name>sizePolicy</name> |
710 | <sizepolicy> | 749 | <sizepolicy> |
711 | <hsizetype>7</hsizetype> | 750 | <hsizetype>7</hsizetype> |
712 | <vsizetype>0</vsizetype> | 751 | <vsizetype>0</vsizetype> |
@@ -735,23 +774,66 @@ | |||
735 | <property> | 774 | <property> |
736 | <name>layoutSpacing</name> | 775 | <name>layoutSpacing</name> |
737 | </property> | 776 | </property> |
738 | <vbox> | 777 | <vbox> |
739 | <property stdset="1"> | 778 | <property stdset="1"> |
740 | <name>margin</name> | 779 | <name>margin</name> |
741 | <number>5</number> | 780 | <number>11</number> |
742 | </property> | 781 | </property> |
743 | <property stdset="1"> | 782 | <property stdset="1"> |
744 | <name>spacing</name> | 783 | <name>spacing</name> |
745 | <number>3</number> | 784 | <number>6</number> |
746 | </property> | 785 | </property> |
747 | <widget> | 786 | <widget> |
748 | <class>QSlider</class> | 787 | <class>QSlider</class> |
749 | <property stdset="1"> | 788 | <property stdset="1"> |
750 | <name>name</name> | 789 | <name>name</name> |
751 | <cstring>brightness_ac_3</cstring> | 790 | <cstring>brightness_ac</cstring> |
791 | </property> | ||
792 | <property stdset="1"> | ||
793 | <name>minValue</name> | ||
794 | <number>0</number> | ||
795 | </property> | ||
796 | <property stdset="1"> | ||
797 | <name>maxValue</name> | ||
798 | <number>255</number> | ||
799 | </property> | ||
800 | <property stdset="1"> | ||
801 | <name>lineStep</name> | ||
802 | <number>16</number> | ||
803 | </property> | ||
804 | <property stdset="1"> | ||
805 | <name>pageStep</name> | ||
806 | <number>16</number> | ||
807 | </property> | ||
808 | <property stdset="1"> | ||
809 | <name>value</name> | ||
810 | <number>255</number> | ||
811 | </property> | ||
812 | <property stdset="1"> | ||
813 | <name>tracking</name> | ||
814 | <bool>true</bool> | ||
815 | </property> | ||
816 | <property stdset="1"> | ||
817 | <name>orientation</name> | ||
818 | <enum>Horizontal</enum> | ||
819 | </property> | ||
820 | <property stdset="1"> | ||
821 | <name>tickmarks</name> | ||
822 | <enum>Right</enum> | ||
823 | </property> | ||
824 | <property> | ||
825 | <name>whatsThis</name> | ||
826 | <string>set a fix value for backlight</string> | ||
827 | </property> | ||
828 | </widget> | ||
829 | <widget> | ||
830 | <class>QSlider</class> | ||
831 | <property stdset="1"> | ||
832 | <name>name</name> | ||
833 | <cstring>contrast_ac</cstring> | ||
752 | </property> | 834 | </property> |
753 | <property stdset="1"> | 835 | <property stdset="1"> |
754 | <name>minValue</name> | 836 | <name>minValue</name> |
755 | <number>0</number> | 837 | <number>0</number> |
756 | </property> | 838 | </property> |
757 | <property stdset="1"> | 839 | <property stdset="1"> |
@@ -899,13 +981,13 @@ | |||
899 | <number>3</number> | 981 | <number>3</number> |
900 | </property> | 982 | </property> |
901 | <widget> | 983 | <widget> |
902 | <class>QCheckBox</class> | 984 | <class>QCheckBox</class> |
903 | <property stdset="1"> | 985 | <property stdset="1"> |
904 | <name>name</name> | 986 | <name>name</name> |
905 | <cstring>auto_brightness_ac_3</cstring> | 987 | <cstring>auto_brightness_ac</cstring> |
906 | </property> | 988 | </property> |
907 | <property stdset="1"> | 989 | <property stdset="1"> |
908 | <name>text</name> | 990 | <name>text</name> |
909 | <string>Use Light Sensor</string> | 991 | <string>Use Light Sensor</string> |
910 | </property> | 992 | </property> |
911 | <property> | 993 | <property> |
@@ -914,13 +996,13 @@ | |||
914 | </property> | 996 | </property> |
915 | </widget> | 997 | </widget> |
916 | <widget> | 998 | <widget> |
917 | <class>QPushButton</class> | 999 | <class>QPushButton</class> |
918 | <property stdset="1"> | 1000 | <property stdset="1"> |
919 | <name>name</name> | 1001 | <name>name</name> |
920 | <cstring>CalibrateLightSensorAC</cstring> | 1002 | <cstring>CalibrateLightSensor_ac</cstring> |
921 | </property> | 1003 | </property> |
922 | <property stdset="1"> | 1004 | <property stdset="1"> |
923 | <name>text</name> | 1005 | <name>text</name> |
924 | <string>Calibrate</string> | 1006 | <string>Calibrate</string> |
925 | </property> | 1007 | </property> |
926 | <property> | 1008 | <property> |
@@ -1189,28 +1271,28 @@ | |||
1189 | </widget> | 1271 | </widget> |
1190 | </vbox> | 1272 | </vbox> |
1191 | </widget> | 1273 | </widget> |
1192 | <images> | 1274 | <images> |
1193 | <image> | 1275 | <image> |
1194 | <name>image0</name> | 1276 | <name>image0</name> |
1195 | <data format="XPM.GZ" length="1265">789c55d34b4fe2601487f13d9fa2811d9960cba5854c66a1584511046f209359f46d8b50b9df1427f3dda7cf31e2e13c2efebf77a118e349deea775a56fe24b3de049b716885a36065e5a3ed74bafffde7d7df4cd671adf4cb2d5b4ef647265bb042ab3d9fc5ec92daaeda35b5ab6adfaa9d533b56db537baaf650ed96da1db5efd53e55fb51ed2bb5376a3fa87da9f656ed62ba733543b002038f605928079f851141471813b485438203686c827d183a049f842ec1b5302038161a82d74239d880914d30103a0467c222c10f6185e099d023b813560946c21ac10ba121d8168604f74239d813c604cf616c13f4850ec177619160222c1334c20ac150e8126c0a3d8237c22ac13b618d6057287f24b8121a824b6148b02e94df014e847270048736c137a14370212c119c0bcb045f851ec117a121f907e4728109a358e6d7db307c496f34566f71f22a37997ebfcde68bc57cb15c99f5e6eb6dbb7b4bef7dbfdf7f9c1edeceea93ba39f77dffe2f076d9484c92186392ddd5e1fb5d376f3eaff1fd335ad152ae7dab3e5fa73b4aefaea53ff37d779e5ef341bf3dca87f68fde0a4f3ddfeff58f7edfc2f3c0769ce2f15ba93c1854dce3b78257ad0d3f57f6dfcfcc7f522034e9</data> | 1277 | <data format="XPM.GZ" length="680">789c5dd04d6ac3301005e0bd4f21ec5d280931b1c0941ca1a5cb42e962a4194956e2d8f9e9a294debd9e9168ec3cbcd0f72ca1b1372bf5fef6a2569be27a835b67950d70512bfceafbef8fcffd4f516eb59a9e7aabb6e55351ae9555afc389787d9ed6556bdbb6b5cc2b1376d0c08e79115a0090b74326258e4cb333b591cd27a66d6c6d1b669fa9134988162c328f99945831b1c11a65f32153271a2121a0cc1c3329b16392a69a3413327562101201c9669f4989c874dad54e36bb4c9d6885ce8173f2df24158049abff0eec14a479371de1f859573944873e00dd3b8353ba18e3e1de1dbcf7d04d31b3b39033eb8e1052aad9bdc64be262bec0b784e5cc81c78387efe0ae5b767decba785a76c3380cc379d9ad2fe3787df82fb394bfcfc51f5517a686</data> |
1196 | </image> | 1278 | </image> |
1197 | <image> | 1279 | <image> |
1198 | <name>image1</name> | 1280 | <name>image1</name> |
1199 | <data format="XPM.GZ" length="2211">789c75d5594fdb401007f0773e45c4bca1eadfc4b755f581fba6d0420b547db077d7248424908310aa7ef7ae6736ee9683c1917ed9b13d9e592b1fd75a97a7c7adb58f2b936931eda996ea16e3d69a9e0d068b9fbf3eff5e59ed24adfabf1db582d50f2bab67d3966a9d8c86a6066df9d8f371e8e3c0c7be8f231fca03c887f131f091fb17e8fad07edad847e5a7f5fc95637f65e8af843e36fcb4898fff6afbeee3c4c7a67f4e0dca4b1b8abd5bbb48eb606fb3f98fbd60ebc214157b836d0a53f28468ddb9727e665765bb0cd93bb5ad6cb09f6aeb5c2589664fd95a9569ccc5ded536460751c98e6a57818ec3845d386771c4ced8a12e42cea7b9d84459c6eb9a1de92a95e79b89ed7aceeb5c7f15ebbccdfdc00f6715707d982c1d49fd8f6293e46c6cb11313c41d76c94e4d9e73bfa09c8b829f8fc0ce4c184b7fc6ce59c6c617766ee250fa113827622a9dd398e7831b6795733f68c4b6e3c9a47f47ecd2a41d9e0f86ce4aee4777ce2693cdd217575129f3b965ab2ac8a59e0bb6362a907ae4feba0a32b1710e3399d7837324cf8f986daa3891fea5ce4922f5edb3ab2ae8c8f9078d797e386c2cf3fde61cba799d3b47813ccfded2a1e45f3ac7915cffbab15cbfdd58f2af1acb7e796e2cfbe56b639977c73971e7274b27b25f17cea9ec77a2c652ef9373964aff8ba533e9d76963b9fed9d2b9bc7f95732eef37769d8b5cfab3dd58eadd59ba90eb3f2e2def33668da5fe7963e9dfb4b1bc5f7de752d6e9c15929ee1fdd3796fdfbcfb25f478da51f3d676de47eb7cec6b9db38935f8c658050a0848286f9f7ad9f830a37e8a267e3167ddcbdcec100438c706f0ff97cc0f855ce0453ccf088b9fd7cc202cf58c7869f834d6c611b3bd8b5c71ef67180431ce1f8bf9c137cc129ceecf115df70ce71f122e73b7ee01257b8461b1d8e3602842fea891023f12245f6aae69c4044850ba292d4ebfe902643958b1beabed543ead12df5edb3cfa94f77347833674823bab7fdbba7071ad3e4ad1c9b35a5193dda98d3d3dbf3b2390b7aa675dab0b1f96ece166dd38e8d5dda7b2fc766edd3011dd291ffddea9f4f2b7f01e4bc2999</data> | 1281 | <data format="XPM.GZ" length="1220">789c5dd35f53e2301000f0773e4507de981ba4a5443a37f7a028fe41101514bcb987344d0515a8b4a0e0dc77bfee6e36d0dbe121bf4d48361b38aa3ae341cfa91e95d24c6633e5a8a95c39d5683d9f6f7ffff9f55d2abbc2c93fcd63c72dff28956b8e72facb8586f1733eae042a080205f480d2974de903eb4825a5c4d927434d9c30435c3c26861ed105863ef31118692584043e18cae306700ad43af27c9cbd00c622120d2cf8c350d65bc02b66230056984d0f786ea83d9c7d67fab89562d2b92ba2f6e8bb4343d10a81236680579086927a1532a957d7c898b7fa32146e1db865d28d7acc26def7de50b6b0aa3b4b2ce3cc507bb8d58c498b0796b8386252cd1b62ec51199f96d8c95326f5aacfa49d6f99b455db50d0e235935ea1c3a43e279678c14ba6c0e62c99f40a5d4bbcc21b931afbc20c23e0c250d2e21b26d5bcb3c4d913265d21b5c417cc9874d09c49bfd857c358e1b931530ba0b6c4ff510da3224345239b8b74bee6657a989bbd62bc1de4dee7108b65f2b1cfadd22ccdd69bcde7d73eb7dd9dec92d376bb7db6cf9d77924e02b1dde72e2e4d5c1d9c7bddbdc9a3db2bd4d74ff3e8176bbe856206c5dc1d947c5fcc3d0c47a3e16331f7349e4c26cfc55cadeebade7f7d3988f2df9fa57f7da120b4</data> |
1200 | </image> | 1282 | </image> |
1201 | </images> | 1283 | </images> |
1202 | <connections> | 1284 | <connections> |
1203 | <connection> | 1285 | <connection> |
1204 | <sender>CalibrateLightSensor</sender> | 1286 | <sender>CalibrateLightSensor</sender> |
1205 | <signal>clicked()</signal> | 1287 | <signal>clicked()</signal> |
1206 | <receiver>LightSettingsBase</receiver> | 1288 | <receiver>LightSettingsBase</receiver> |
1207 | <slot>calibrateSensor()</slot> | 1289 | <slot>calibrateSensor()</slot> |
1208 | </connection> | 1290 | </connection> |
1209 | <connection> | 1291 | <connection> |
1210 | <sender>CalibrateLightSensorAC</sender> | 1292 | <sender>CalibrateLightSensor_ac</sender> |
1211 | <signal>clicked()</signal> | 1293 | <signal>clicked()</signal> |
1212 | <receiver>LightSettingsBase</receiver> | 1294 | <receiver>LightSettingsBase</receiver> |
1213 | <slot>calibrateSensorAC()</slot> | 1295 | <slot>calibrateSensorAC()</slot> |
1214 | </connection> | 1296 | </connection> |
1215 | <slot access="public">calibrateSensor()</slot> | 1297 | <slot access="public">calibrateSensor()</slot> |
1216 | <slot access="public">calibrateSensorAC()</slot> | 1298 | <slot access="public">calibrateSensorAC()</slot> |
@@ -1221,18 +1303,18 @@ | |||
1221 | <tabstop>interval_suspend</tabstop> | 1303 | <tabstop>interval_suspend</tabstop> |
1222 | <tabstop>LcdOffOnly</tabstop> | 1304 | <tabstop>LcdOffOnly</tabstop> |
1223 | <tabstop>brightness</tabstop> | 1305 | <tabstop>brightness</tabstop> |
1224 | <tabstop>auto_brightness</tabstop> | 1306 | <tabstop>auto_brightness</tabstop> |
1225 | <tabstop>CalibrateLightSensor</tabstop> | 1307 | <tabstop>CalibrateLightSensor</tabstop> |
1226 | <tabstop>tabs</tabstop> | 1308 | <tabstop>tabs</tabstop> |
1227 | <tabstop>interval_lightoff_ac_3</tabstop> | 1309 | <tabstop>interval_lightoff_ac</tabstop> |
1228 | <tabstop>interval_suspend_ac_3</tabstop> | 1310 | <tabstop>interval_suspend_ac</tabstop> |
1229 | <tabstop>interval_dim_ac_3</tabstop> | 1311 | <tabstop>interval_dim_ac</tabstop> |
1230 | <tabstop>LcdOffOnly_2_3</tabstop> | 1312 | <tabstop>LcdOffOnly_ac</tabstop> |
1231 | <tabstop>brightness_ac_3</tabstop> | 1313 | <tabstop>brightness_ac</tabstop> |
1232 | <tabstop>auto_brightness_ac_3</tabstop> | 1314 | <tabstop>auto_brightness_ac</tabstop> |
1233 | <tabstop>CalibrateLightSensorAC</tabstop> | 1315 | <tabstop>CalibrateLightSensor_ac</tabstop> |
1234 | <tabstop>lowSpinBox</tabstop> | 1316 | <tabstop>lowSpinBox</tabstop> |
1235 | <tabstop>warnintervalBox</tabstop> | 1317 | <tabstop>warnintervalBox</tabstop> |
1236 | <tabstop>criticalSpinBox</tabstop> | 1318 | <tabstop>criticalSpinBox</tabstop> |
1237 | </tabstops> | 1319 | </tabstops> |
1238 | </UI> | 1320 | </UI> |