|
|
@@ -2129,6 +2129,18 @@ void TransmitterSwitch::updateCountDown()
|
|
|
{
|
|
|
QString strConfigPath = QApplication::applicationDirPath() + m_configName;
|
|
|
QSettings setting(strConfigPath, QSettings::IniFormat);
|
|
|
+ if(setting.status() != QSettings::NoError)
|
|
|
+ {
|
|
|
+ LH_WRITE_ERROR("读取配置文件失败,使用默认倒计时间隔10分钟");
|
|
|
+ m_countdownInterval = 10 * 60;
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ if(!setting.contains("System/PlanTimeSpace"))
|
|
|
+ {
|
|
|
+ LH_WRITE_ERROR("没有找到PlanTimeSpace配置项,使用默认倒计时间隔10分钟");
|
|
|
+ m_countdownInterval = 10 * 60;
|
|
|
+ return;
|
|
|
+ }
|
|
|
setting.beginGroup("System");
|
|
|
int countDown = setting.value("PlanTimeSpace", 10).toInt();
|
|
|
setting.endGroup();
|