Fix multiselection by CTRL-click in QFileDialog/KDE.
Task-number: QTBUG-29257 Change-Id: Idfac80e855455a4537dd38a23136762cd9398e15 Reviewed-by: David Faure (KDE) <faure@kde.org> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
This commit is contained in:
parent
e28c03cb82
commit
b6ccdfa482
@ -2966,7 +2966,11 @@ void QFileDialogPrivate::_q_enterDirectory(const QModelIndex &index)
|
||||
lineEdit()->clear();
|
||||
}
|
||||
} else {
|
||||
q->accept();
|
||||
// Do not accept when shift-clicking to multi-select a file in environments with single-click-activation (KDE)
|
||||
if (!q->style()->styleHint(QStyle::SH_ItemView_ActivateItemOnSingleClick)
|
||||
|| q->fileMode() != QFileDialog::ExistingFiles || !(QGuiApplication::keyboardModifiers() & Qt::CTRL)) {
|
||||
q->accept();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user