Drop use of Qt::DefaultLocaleShortDate

Gone in Qt 6.

Task-number: QTCREATORBUG-24098
Change-Id: Ie9fe1858406133fed6987de0e0a38fe86de15caf
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
hjk
2020-06-19 18:49:17 +02:00
parent 467fdead9f
commit e6d1f08642
4 changed files with 9 additions and 6 deletions

View File

@@ -180,9 +180,11 @@ bool CorePlugin::initialize(const QStringList &arguments, QString *errorMessage)
expander->registerVariable("CurrentTime:RFC", tr("The current time (RFC2822)."),
[]() { return QTime::currentTime().toString(Qt::RFC2822Date); });
expander->registerVariable("CurrentDate:Locale", tr("The current date (Locale)."),
[]() { return QDate::currentDate().toString(Qt::DefaultLocaleShortDate); });
[]() { return QLocale::system()
.toString(QDate::currentDate(), QLocale::ShortFormat); });
expander->registerVariable("CurrentTime:Locale", tr("The current time (Locale)."),
[]() { return QTime::currentTime().toString(Qt::DefaultLocaleShortDate); });
[]() { return QLocale::system()
.toString(QTime::currentTime(), QLocale::ShortFormat); });
expander->registerVariable("Config:DefaultProjectDirectory", tr("The configured default directory for projects."),
[]() { return DocumentManager::projectsDirectory().toString(); });
expander->registerVariable("Config:LastFileDialogDirectory", tr("The directory last visited in a file dialog."),