summaryrefslogtreecommitdiffstats
path: root/qt-ui/mainwindow.cpp
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2014-06-30 14:42:48 -0700
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-06-30 14:42:48 -0700
commit5149bc0df8b8f2b813911f360eca994e323b1138 (patch)
tree3c995c27ba264b0ec48936145b21957810421b84 /qt-ui/mainwindow.cpp
parent8315f44d2c447d5a6a1dcd9c505cb85fd73469be (diff)
downloadsubsurface-5149bc0df8b8f2b813911f360eca994e323b1138.tar.gz
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 <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/mainwindow.cpp')
-rw-r--r--qt-ui/mainwindow.cpp7
1 files changed, 5 insertions, 2 deletions
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