QNX: don't copy a QStringList twice every loop iteration
Apparently, the function before returned const-&, but now returns by-value. Use the member data variable directly, the function is const anyway. Change-Id: I324bc675fd7c9b5bfb28c475eba0c0275379132c Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>bb10
parent
e009a3156b
commit
396e3a18d7
|
|
@ -288,8 +288,8 @@ QString QQnxFilePicker::filePickerType() const
|
|||
bool video = false;
|
||||
bool music = false;
|
||||
QMimeDatabase mimeDb;
|
||||
for (int i = 0; i < filters().count(); i++) {
|
||||
QList<QMimeType> mimeTypes = mimeDb.mimeTypesForFileName(filters().at(i));
|
||||
for (int i = 0; i < m_filters.count(); i++) {
|
||||
QList<QMimeType> mimeTypes = mimeDb.mimeTypesForFileName(m_filters.at(i));
|
||||
if (mimeTypes.isEmpty())
|
||||
return QStringLiteral("Other");
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue