mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-28 07:51:11 +02:00
update_settings.cpp: split statement for update settings notify
Avoid double action
Origin commit data
------------------
Branch: ni/coolstream
Commit: e553e427a9
Author: Thilo Graf <dbt@novatux.de>
Date: 2021-04-12 (Mon, 12 Apr 2021)
------------------
This commit was generated by Migit
This commit is contained in:
@@ -199,20 +199,19 @@ int CUpdateSettings::initMenu()
|
|||||||
|
|
||||||
bool CUpdateSettings::changeNotify(const neutrino_locale_t OptionName, void * /* data */)
|
bool CUpdateSettings::changeNotify(const neutrino_locale_t OptionName, void * /* data */)
|
||||||
{
|
{
|
||||||
if (ARE_LOCALES_EQUAL(OptionName, LOCALE_FLASHUPDATE_AUTOCHECK) || ARE_LOCALES_EQUAL(OptionName, LOCALE_FLASHUPDATE_AUTOCHECK_PACKAGES))
|
if (ARE_LOCALES_EQUAL(OptionName, LOCALE_FLASHUPDATE_AUTOCHECK))
|
||||||
{
|
{
|
||||||
CFlashUpdateCheck::getInstance()->stopThread();
|
CFlashUpdateCheck::getInstance()->stopThread();
|
||||||
if (g_settings.softupdate_autocheck)
|
if (g_settings.softupdate_autocheck)
|
||||||
CFlashUpdateCheck::getInstance()->startThread();
|
CFlashUpdateCheck::getInstance()->startThread();
|
||||||
|
}
|
||||||
#if ENABLE_PKG_MANAGEMENT
|
#if ENABLE_PKG_MANAGEMENT
|
||||||
CUpdateCheck::getInstance()->stopTimer();
|
if (ARE_LOCALES_EQUAL(OptionName, LOCALE_FLASHUPDATE_AUTOCHECK_PACKAGES))
|
||||||
if (g_settings.softupdate_autocheck)
|
{
|
||||||
CUpdateCheck::getInstance()->startThread();
|
|
||||||
CUpdateCheckPackages::getInstance()->stopTimer();
|
CUpdateCheckPackages::getInstance()->stopTimer();
|
||||||
if (g_settings.softupdate_autocheck_packages)
|
if (g_settings.softupdate_autocheck_packages)
|
||||||
CUpdateCheckPackages::getInstance()->startThread();
|
CUpdateCheckPackages::getInstance()->startThread();
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@@ -3150,7 +3150,6 @@ TIMER_STOP("################################## after all #######################
|
|||||||
delete hintBox;
|
delete hintBox;
|
||||||
#endif
|
#endif
|
||||||
CFlashUpdateCheck::getInstance()->startThread();
|
CFlashUpdateCheck::getInstance()->startThread();
|
||||||
//CUpdateCheck::getInstance()->startThread();
|
|
||||||
}
|
}
|
||||||
#if ENABLE_PKG_MANAGEMENT
|
#if ENABLE_PKG_MANAGEMENT
|
||||||
if (g_settings.softupdate_autocheck_packages)
|
if (g_settings.softupdate_autocheck_packages)
|
||||||
|
Reference in New Issue
Block a user