Increased maximum time limit for timers to 50000 min (almost 35 days). This relates to bug 2599.

NOTE: if the max limit is removed, the TQSpinBox reverts to the default value of 99.
Also fixed minimum limit for some timers and percentage fields.

Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
(cherry picked from commit 2f0cf5202c)
r14.0.x
Michele Calgaro 9 years ago
parent 3063d5b1dc
commit 504511d4a5

@ -327,7 +327,10 @@
<string> min</string>
</property>
<property name="maxValue">
<number>1500</number>
<number>50000</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
<widget class="TQSpinBox" row="5" column="3">
@ -341,7 +344,10 @@
<string> min</string>
</property>
<property name="maxValue">
<number>1500</number>
<number>50000</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
<widget class="TQSpinBox" row="4" column="3">
@ -355,7 +361,10 @@
<string> min</string>
</property>
<property name="maxValue">
<number>1500</number>
<number>50000</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
</grid>
@ -656,6 +665,12 @@
<property name="suffix">
<string> min</string>
</property>
<property name="maxValue">
<number>50000</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
<widget class="TQPushButton" row="5" column="2" rowspan="1" colspan="2">
<property name="name">
@ -881,7 +896,7 @@
<string> %</string>
</property>
<property name="maxValue">
<number>1500</number>
<number>100</number>
</property>
</widget>
<widget class="TQLabel" row="2" column="3" rowspan="1" colspan="2">
@ -944,6 +959,12 @@
<property name="suffix">
<string> min</string>
</property>
<property name="maxValue">
<number>50000</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
</grid>
</widget>
@ -1329,6 +1350,9 @@
<property name="maxValue">
<number>100</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
<widget class="TQSpinBox" row="3" column="6">
<property name="name">
@ -1348,6 +1372,9 @@
<property name="maxValue">
<number>100</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
<widget class="TQSpinBox" row="1" column="2">
<property name="name">
@ -1367,6 +1394,9 @@
<property name="maxValue">
<number>100</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
<widget class="TQSpinBox" row="2" column="2">
<property name="name">
@ -1386,6 +1416,9 @@
<property name="maxValue">
<number>100</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
<widget class="TQSpinBox" row="3" column="2">
<property name="name">
@ -1405,6 +1438,9 @@
<property name="maxValue">
<number>100</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
<widget class="TQSpinBox" row="1" column="6">
<property name="name">
@ -1424,6 +1460,9 @@
<property name="maxValue">
<number>100</number>
</property>
<property name="minValue">
<number>1</number>
</property>
</widget>
</grid>
</widget>

@ -32,8 +32,8 @@ extern "C" {
#include <X11/extensions/dpms.h>
#include <X11/extensions/scrnsaver.h>
}
// KDE Headers
// TDE Headers
#include <tdelocale.h>
/*! The default constructor of the class autosuspend */
@ -93,7 +93,7 @@ void inactivity::start( int timeToExpire, TQStringList blacked ) {
}
/*!
* \b TQT_SLOT to call check as recheck inactivity if befor a running PID
* \b TQT_SLOT to call check as recheck inactivity if before a running PID
* request was detected.
*/
void inactivity::recheck() {

@ -101,7 +101,7 @@ tdepowersave::tdepowersave( bool force_acpi_check, bool trace_func ) : KSystemTr
connect(hwinfo, TQT_SIGNAL(ACStatus(bool)), this, TQT_SLOT(handleACStatusChange (bool)));
connect(hwinfo, TQT_SIGNAL(resumed(int)), this, TQT_SLOT(forwardResumeSignal(int)));
// connect to error mesages
// connect to error messages
connect(autoSuspend, TQT_SIGNAL(displayErrorMsg(TQString)), this, TQT_SLOT(showErrorMessage(TQString)));
// connect to events
@ -747,7 +747,7 @@ bool tdepowersave::do_suspend2disk(){
/*!
* \b TQT_SLOT to send the command for "suspend to RAM" to the TDE hardware library.
* If there is a error while "suspend to RAM" the user get e messagebox.
* If there is a error while "suspend to RAM" the user get a messagebox.
* This function need a power management backend in TDE hardware library for "suspend to RAM".
* \return boolean with the result of the operation
* \retval true if successful
@ -986,11 +986,11 @@ void tdepowersave::do_autosuspendWarn() {
/*!
* \b TQT_SLOT to send the related suspend command for autosuspend
* \param chancel boolean with info if the autosuspend should get chanceld
* \param chancel boolean with info if the autosuspend should get canceled
* \return boolean with the result of the operation
* \retval true if successful
* \retval false if command not supported or on any other error
* \todo add check if the requested command is supported befor send and
* \todo add check if the requested command is supported before send and
* add message for this case to tell that maybe changed config!
*/
bool tdepowersave::do_autosuspend(bool chancel) {
@ -1021,7 +1021,7 @@ bool tdepowersave::do_autosuspend(bool chancel) {
return false;
}
} else {
kdDebug() << "The autosuspend was chanceled (via the chancel dialog), start again." << endl;
kdDebug() << "The autosuspend was canceled (via the cancel dialog), start again." << endl;
setAutoSuspend(false);
return false;
}

Loading…
Cancel
Save