QFileDialog: use QSignalBlocker

Change-Id: I32a631493138a777458557232da084f497adc526
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
This commit is contained in:
Marc Mutz 2013-10-25 19:47:37 +02:00 committed by The Qt Project
parent 3549dfe8b8
commit 4003d44ca2

View File

@ -2612,9 +2612,8 @@ void QFileDialog::accept()
// special case for ".."
if (lineEditText == QLatin1String("..")) {
d->_q_navigateToParent();
bool block = d->qFileDialogUi->fileNameEdit->blockSignals(true);
const QSignalBlocker blocker(d->qFileDialogUi->fileNameEdit);
d->lineEdit()->selectAll();
d->qFileDialogUi->fileNameEdit->blockSignals(block);
return;
}