mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-07-11 00:59:29 -04:00
Restore compatibility with old Qt versions.
This commit is contained in:
parent
9321943e64
commit
586de64293
1 changed files with 2 additions and 4 deletions
|
@ -183,7 +183,6 @@ QStringList QCommandLineOption::names() const
|
||||||
void QCommandLineOptionPrivate::setNames(const QStringList &nameList)
|
void QCommandLineOptionPrivate::setNames(const QStringList &nameList)
|
||||||
{
|
{
|
||||||
QStringList newNames;
|
QStringList newNames;
|
||||||
newNames.reserve(nameList.size());
|
|
||||||
if (nameList.isEmpty())
|
if (nameList.isEmpty())
|
||||||
qWarning("QCommandLineOption: Options must have at least one name");
|
qWarning("QCommandLineOption: Options must have at least one name");
|
||||||
Q_FOREACH (const QString &name, nameList) {
|
Q_FOREACH (const QString &name, nameList) {
|
||||||
|
@ -202,7 +201,7 @@ void QCommandLineOptionPrivate::setNames(const QStringList &nameList)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// commit
|
// commit
|
||||||
names.swap(newNames);
|
names = newNames;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
@ -276,11 +275,10 @@ void QCommandLineOption::setDefaultValue(const QString &defaultValue)
|
||||||
{
|
{
|
||||||
QStringList newDefaultValues;
|
QStringList newDefaultValues;
|
||||||
if (!defaultValue.isEmpty()) {
|
if (!defaultValue.isEmpty()) {
|
||||||
newDefaultValues.reserve(1);
|
|
||||||
newDefaultValues << defaultValue;
|
newDefaultValues << defaultValue;
|
||||||
}
|
}
|
||||||
// commit:
|
// commit:
|
||||||
d->defaultValues.swap(newDefaultValues);
|
d->defaultValues = newDefaultValues;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue