mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
User survey: force running the survey from command line
This way people can test the dialog much easier. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
181d4e2fa6
commit
8bd535d092
3 changed files with 17 additions and 11 deletions
|
@ -827,16 +827,15 @@ void MainWindow::checkSurvey(QSettings *s)
|
|||
if (!s->contains("FirstUse42")) {
|
||||
QVariant value = QDate().currentDate();
|
||||
s->setValue("FirstUse42", value);
|
||||
} else {
|
||||
// wait a week for production versions, but not at all for non-tagged builds
|
||||
QString ver(VERSION_STRING);
|
||||
int waitTime = ver.contains('-') ? -1 : 7;
|
||||
QDate firstUse42 = s->value("FirstUse42").toDate();
|
||||
if (firstUse42.daysTo(QDate().currentDate()) > waitTime && !s->contains("SurveyDone")) {
|
||||
if (!survey)
|
||||
survey = new UserSurvey(this);
|
||||
survey->show();
|
||||
}
|
||||
}
|
||||
// wait a week for production versions, but not at all for non-tagged builds
|
||||
QString ver(VERSION_STRING);
|
||||
int waitTime = ver.contains('-') ? -1 : 7;
|
||||
QDate firstUse42 = s->value("FirstUse42").toDate();
|
||||
if (run_survey || (firstUse42.daysTo(QDate().currentDate()) > waitTime && !s->contains("SurveyDone"))) {
|
||||
if (!survey)
|
||||
survey = new UserSurvey(this);
|
||||
survey->show();
|
||||
}
|
||||
s->endGroup();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue