mirror of
https://github.com/jankae/LibreVNA.git
synced 2026-04-05 06:25:16 +00:00
reset preferences command line option
This commit is contained in:
parent
c5973fb0ea
commit
97fceb4ff4
1 changed files with 6 additions and 1 deletions
|
|
@ -181,10 +181,15 @@ AppWindow::AppWindow(QWidget *parent)
|
|||
parser.addOption(QCommandLineOption("no-gui", "Disables the graphical interface"));
|
||||
parser.addOption(QCommandLineOption("cal", "Calibration file to load on startup", "cal"));
|
||||
parser.addOption(QCommandLineOption("setup", "Setup file to load on startup", "setup"));
|
||||
parser.addOption(QCommandLineOption("reset-preferences", "Resets all preferences to their default values"));
|
||||
|
||||
parser.process(QCoreApplication::arguments());
|
||||
|
||||
Preferences::getInstance().load();
|
||||
if(parser.isSet("reset-preferences")) {
|
||||
Preferences::getInstance().setDefault();
|
||||
} else {
|
||||
Preferences::getInstance().load();
|
||||
}
|
||||
device = nullptr;
|
||||
|
||||
if(parser.isSet("port")) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue