mirror of
https://github.com/tnodir/fort
synced 2024-11-15 05:46:03 +00:00
UI: Simplify booted provider's uninstalling.
This commit is contained in:
parent
5f4236f672
commit
288b55529c
@ -74,7 +74,7 @@ Filename: "https://support.microsoft.com/en-us/help/2977003/the-latest-supported
|
||||
|
||||
[UninstallRun]
|
||||
Filename: "{app}\driver\scripts\uninstall.bat"; RunOnceId: "DelDriver"; Flags: runascurrentuser
|
||||
Filename: "{#APP_EXE}"; Parameters: "-b=0"; RunOnceId: "DelProvider"; Flags: runascurrentuser
|
||||
Filename: "{#APP_EXE}"; Parameters: "-u"; RunOnceId: "DelProvider"; Flags: runascurrentuser
|
||||
|
||||
[InstallDelete]
|
||||
Type: filesandordirs; Name: "{app}\driver"
|
||||
|
@ -27,7 +27,6 @@ FortSettings::FortSettings(QObject *parent) :
|
||||
m_iniExists(false),
|
||||
m_isPortable(false),
|
||||
m_noCache(false),
|
||||
m_hasProvBoot(false),
|
||||
m_bulkUpdating(false),
|
||||
m_bulkIniChanged(false)
|
||||
{
|
||||
@ -91,11 +90,6 @@ void FortSettings::processArguments(const QStringList &args, EnvManager *envMana
|
||||
{
|
||||
QCommandLineParser parser;
|
||||
|
||||
const QCommandLineOption provBootOption(QStringList() << "b"
|
||||
<< "boot",
|
||||
"Unblock access to network when Fort Firewall is not running.", "boot");
|
||||
parser.addOption(provBootOption);
|
||||
|
||||
const QCommandLineOption profileOption(QStringList() << "p"
|
||||
<< "profile",
|
||||
"Directory to store settings.", "profile");
|
||||
@ -138,9 +132,6 @@ void FortSettings::processArguments(const QStringList &args, EnvManager *envMana
|
||||
m_noCache = true;
|
||||
}
|
||||
|
||||
// Provider Boot
|
||||
m_hasProvBoot = parser.isSet(provBootOption);
|
||||
|
||||
// Default Language
|
||||
if (parser.isSet(langOption)) {
|
||||
m_defaultLanguage = parser.value(langOption);
|
||||
|
@ -68,7 +68,6 @@ public:
|
||||
|
||||
bool isPortable() const { return m_isPortable; }
|
||||
bool noCache() const { return m_noCache; }
|
||||
bool hasProvBoot() const { return m_hasProvBoot; }
|
||||
|
||||
bool debug() const { return iniBool("base/debug"); }
|
||||
void setDebug(bool on) { setIniValue("base/debug", on); }
|
||||
@ -329,7 +328,6 @@ private:
|
||||
bool m_iniExists : 1;
|
||||
bool m_isPortable : 1;
|
||||
bool m_noCache : 1;
|
||||
bool m_hasProvBoot : 1;
|
||||
|
||||
bool m_bulkUpdating : 1;
|
||||
bool m_bulkIniChanged : 1;
|
||||
|
@ -21,6 +21,12 @@
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
// Uninstall: Unregister booted provider and exit
|
||||
if (argc > 1 && !strcmp(argv[1], "-u")) {
|
||||
FortCommon::provUnregister();
|
||||
return 0;
|
||||
}
|
||||
|
||||
FortSettings fortSettings;
|
||||
|
||||
// Process global settings required before QApplication costruction
|
||||
@ -42,12 +48,6 @@ int main(int argc, char *argv[])
|
||||
// Initialize with command line arguments
|
||||
fortSettings.initialize(QCoreApplication::arguments(), &envManager);
|
||||
|
||||
// Unregister booted provider and exit
|
||||
if (fortSettings.hasProvBoot()) {
|
||||
FortCommon::provUnregister();
|
||||
return 0;
|
||||
}
|
||||
|
||||
#ifdef USE_CONTROL_COMMANDS
|
||||
ControlManager controlManager(QApplication::applicationName(), fortSettings.controlCommand());
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user