Refresh killSwitch state update

This commit is contained in:
Mykola Baibuz 2025-02-19 15:54:21 +02:00
parent 13fd957647
commit 7a926f2eef

View file

@ -54,19 +54,19 @@ bool KillSwitch::init()
bool KillSwitch::refresh(bool enabled)
{
#ifdef Q_OS_WIN
#if defined(Q_OS_WIN)
QSettings RegHLM("HKEY_LOCAL_MACHINE\\Software\\" + QString(ORGANIZATION_NAME)
+ "\\" + QString(APPLICATION_NAME), QSettings::NativeFormat);
RegHLM.setValue("strictKillSwitchEnabled", enabled);
#endif
#elif
m_appSettigns->setValue("Conf/strictKillSwitchEnabled", enabled);
#endif
if (isStrictKillSwitchEnabled()) {
return disableAllTraffic();
} else {
return disableKillSwitch();
}
}
bool KillSwitch::isStrictKillSwitchEnabled()