summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/globals.cpp1
-rw-r--r--src/globals.h1
-rw-r--r--src/main.cpp9
3 files changed, 10 insertions, 1 deletions
diff --git a/src/globals.cpp b/src/globals.cpp
index b580bbe..31e54d5 100644
--- a/src/globals.cpp
+++ b/src/globals.cpp
@@ -19,6 +19,7 @@ const QString userConfFile(userPath + "/vmchooser.conf");
const QString previousSessionFile(userPath + "/vmchooser_prev_session");
bool debugMode = false;
+bool pvsEnabled = false;
QString pool;
QString theme;
diff --git a/src/globals.h b/src/globals.h
index b36c959..d46db63 100644
--- a/src/globals.h
+++ b/src/globals.h
@@ -17,6 +17,7 @@
class QString;
extern bool debugMode;
+extern bool pvsEnabled;
extern QString binPath;
extern QString etcPath;
diff --git a/src/main.cpp b/src/main.cpp
index 1fe6401..f5853be 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -183,7 +183,14 @@ int main(int argc, char *argv[]) {
w.setTheme();
w.setWindowFlags(Qt::FramelessWindowHint);
- if (cmdOptions.contains("pvs"))
+ if (cmdOptions.contains("pvs")) {
+ pvsEnabled = true;
+ } else if (settings.contains("pvs")) {
+ if (settings.value("pvs").toInt() == 1)
+ pvsEnabled = true;
+ }
+
+ if ( pvsEnabled )
w.showSettingsPVS();
w.resize(width, height);