mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-11-07 10:33:24 -08:00
[Tutorial] Seed tutorialCompleted for existing installs at startup
This commit is contained in:
parent
121ed9a8a6
commit
61a2923f40
2 changed files with 12 additions and 8 deletions
|
|
@ -205,14 +205,6 @@ bool InterfaceSettings::getShowGameSelectorFilterToolbar() const
|
|||
|
||||
bool InterfaceSettings::getTutorialCompleted() const
|
||||
{
|
||||
// Upgrading users have settings files but no tutorial key yet: treat the tutorial as seen so they are
|
||||
// not overlaid on upgrade. Genuinely new installs have no settings files at all, so they still get it.
|
||||
if (!getSettings().contains("interface/tutorialCompleted")) {
|
||||
QDir settingsDir = QFileInfo(settingPath).dir();
|
||||
if (!settingsDir.entryList({"*.ini"}, QDir::Files).isEmpty()) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return getValue("tutorialCompleted", QString(), QString(), false).toBool();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue