summaryrefslogtreecommitdiffstats
path: root/src/widgets/dialogs
diff options
context:
space:
mode:
authorSérgio Martins <sergio.martins@kdab.com>2015-07-01 17:23:10 +0100
committerMarc Mutz <marc.mutz@kdab.com>2015-07-04 06:03:21 +0000
commitebe4ab04ca156c64a5c56a6fca877654b451fe3d (patch)
tree83cf0a47657c2d3deadca672661358fb34d9cd77 /src/widgets/dialogs
parent0698f876ca02b85c1e584b72cac3444796f6a355 (diff)
Use const-ref in foreach if T is big or non-trivial
Criteria: Linux x86_64, sizeof(T) > 8 Change-Id: I78c2b776ff219fa1ff6632fde17ae25fae66c54e Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Diffstat (limited to 'src/widgets/dialogs')
-rw-r--r--src/widgets/dialogs/qfiledialog.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/widgets/dialogs/qfiledialog.cpp b/src/widgets/dialogs/qfiledialog.cpp
index d83f6609b8..a200fd4d4c 100644
--- a/src/widgets/dialogs/qfiledialog.cpp
+++ b/src/widgets/dialogs/qfiledialog.cpp
@@ -2972,7 +2972,7 @@ void QFileDialogPrivate::createWidgets()
q->setHistory(options->history());
if (options->initiallySelectedFiles().count() == 1)
q->selectFile(options->initiallySelectedFiles().first().fileName());
- foreach (QUrl url, options->initiallySelectedFiles())
+ foreach (const QUrl &url, options->initiallySelectedFiles())
q->selectUrl(url);
lineEdit()->selectAll();
_q_updateOkButton();