From e318a1690e30986026e8428442003dc9e1640371 Mon Sep 17 00:00:00 2001 From: J-P Nurmi Date: Mon, 12 Feb 2018 12:25:10 +0100 Subject: QQuickCheckDelegate: don't consider partially checked as checked Same as fbcdccc for QQuickCheckBox. It was noticed missing from the delegate counterpart while updating the "New Features in Qt 5.11" wiki page. [ChangeLog][Important Behavior Changes] CheckDelegate no longer considers the partially checked state as a checked state. This fixes check state cycling for a non-tri-state check delegate so that it goes from partially checked to fully checked state. Task-number: QTBUG-56295 Change-Id: I1de29178c265e027fdb91ba0b4604b110ddba06a Reviewed-by: Mitch Curtis --- src/quicktemplates2/qquickcheckdelegate.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/quicktemplates2/qquickcheckdelegate.cpp b/src/quicktemplates2/qquickcheckdelegate.cpp index 9b0a8064..b53877df 100644 --- a/src/quicktemplates2/qquickcheckdelegate.cpp +++ b/src/quicktemplates2/qquickcheckdelegate.cpp @@ -167,7 +167,7 @@ void QQuickCheckDelegate::setCheckState(Qt::CheckState state) return; bool wasChecked = isChecked(); - d->checked = state != Qt::Unchecked; + d->checked = state == Qt::Checked; d->checkState = state; emit checkStateChanged(); if (d->checked != wasChecked) -- cgit v1.2.3