system/settings: use integers for shutdown_count/_min

Signed-off-by: Jacek Jendrzej <crashdvb@googlemail.com>


Origin commit data
------------------
Commit: d125301ede
Author: martii <m4rtii@gmx.de>
Date: 2013-12-24 (Tue, 24 Dec 2013)
This commit is contained in:
martii
2013-12-24 09:53:20 +01:00
committed by Jacek Jendrzej
parent 936cdc41dc
commit cc2a63f1ad
5 changed files with 31 additions and 24 deletions

View File

@@ -61,7 +61,7 @@ int CSleepTimerWidget::exec(CMenuTarget* parent, const std::string &actionKey)
parent->hide();
if(permanent) {
strcpy(value,g_settings.shutdown_min);
sprintf(value,"%03d", g_settings.shutdown_min);
} else {
shutdown_min = g_Timerd->getSleepTimerRemaining(); // remaining shutdown time?
sprintf(value,"%03d", shutdown_min);
@@ -100,8 +100,8 @@ int CSleepTimerWidget::exec(CMenuTarget* parent, const std::string &actionKey)
int new_val = atoi(value);
if(permanent) {
sprintf(g_settings.shutdown_min,"%03d", new_val);
printf("permanent sleeptimer min: %s\n", g_settings.shutdown_min);
g_settings.shutdown_min = new_val;
printf("permanent sleeptimer min: %d\n", g_settings.shutdown_min);
}
else if(shutdown_min != new_val) {
shutdown_min = new_val;