From 5149bc0df8b8f2b813911f360eca994e323b1138 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Mon, 30 Jun 2014 14:42:48 -0700 Subject: User survey: don't ask more than once per invocation Otherwise when the user selects "Ask Again" they will get asked when they change preferences. Signed-off-by: Dirk Hohndel --- qt-ui/mainwindow.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'qt-ui/mainwindow.cpp') diff --git a/qt-ui/mainwindow.cpp b/qt-ui/mainwindow.cpp index ab01794af..28e4d7415 100644 --- a/qt-ui/mainwindow.cpp +++ b/qt-ui/mainwindow.cpp @@ -809,6 +809,7 @@ const char *getSetting(QSettings &s, QString name) void MainWindow::readSettings() { + static bool firstRun = true; QSettings s; s.beginGroup("Display"); QFont defaultFont = QFont(default_prefs.divelist_font); @@ -848,9 +849,11 @@ void MainWindow::readSettings() } QNetworkProxy::setApplicationProxy(proxy); - loadRecentFiles(&s); - checkSurvey(&s); + if (firstRun) { + checkSurvey(&s); + firstRun = false; + } } #undef TOOLBOX_PREF_BUTTON -- cgit v1.2.3-70-g09d2