diff options
author | Waqar Ahmed <waqar.ahmed@kdab.com> | 2021-08-16 11:56:52 +0500 |
---|---|---|
committer | Waqar Ahmed <waqar.17a@gmail.com> | 2021-08-18 08:50:54 +0500 |
commit | 3c625b77529f1e5348e568b25852a6e5f1f159b0 (patch) | |
tree | 80a5a0a885f079410aaa662530ec6e86b19a1f5d /src/gui/kernel | |
parent | 74705ae17b29ad560d1d6ad741bdb065ad7a0751 (diff) |
QFileDialog: Use static const QRegularExpression
This avoids rebuilding the same pattern. Caught by clazy.
Change-Id: Ibd0f2063617df1a9e975f58e34df556d1983afff
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Diffstat (limited to 'src/gui/kernel')
-rw-r--r-- | src/gui/kernel/qplatformdialoghelper.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/kernel/qplatformdialoghelper.cpp b/src/gui/kernel/qplatformdialoghelper.cpp index 82b60b7749..9ed2557ad9 100644 --- a/src/gui/kernel/qplatformdialoghelper.cpp +++ b/src/gui/kernel/qplatformdialoghelper.cpp @@ -771,7 +771,7 @@ const char QPlatformFileDialogHelper::filterRegExp[] = QStringList QPlatformFileDialogHelper::cleanFilterList(const QString &filter) { #if QT_CONFIG(regularexpression) - QRegularExpression regexp(QString::fromLatin1(filterRegExp)); + static const QRegularExpression regexp(QString::fromLatin1(filterRegExp)); Q_ASSERT(regexp.isValid()); QString f = filter; QRegularExpressionMatch match = regexp.match(filter); |