summaryrefslogtreecommitdiffstats
path: root/src/widgets/widgets/qcheckbox.h
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@qt.io>2023-08-11 21:22:57 +0200
committerVolker Hilsheimer <volker.hilsheimer@qt.io>2023-09-05 13:43:44 +0000
commit5a96d13bb5abd5339cf21dd1de7a17152c71f0fc (patch)
tree03a4f9423a53b46168f26f3fc80ae6651d8c9ae4 /src/widgets/widgets/qcheckbox.h
parent4367abb75a8ce07344006efd17317d5ad8e03f5f (diff)
QCheckBox: add new checkStateChanged(Qt::CheckState) signal
... to replace the old stateChanged(int) one, which a) had the wrong name and b) the wrong argument type. Mark the old one as \obsolete, so new users don't see it anymore. Prepare for deprecation in the test, but don't actually deprecate, yet (this author does not know how to deprecate signals). Found in API-review. Amends 37b47ebf946ef1a37573107375fbe5fc0eb1e6d2. As a drive-by, replace explicit qWait() calls with QTRY_COMPARE(). [ChangeLog][QtWidgets][QCheckBox] Added new checkStateChanged(Qt::CheckState) signal, obsoleting stateChanged(int). Fixes: QTBUG-104688 Change-Id: I01791fd003b752c47d99bea65151202be9175c21 Reviewed-by: Axel Spoerl <axel.spoerl@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'src/widgets/widgets/qcheckbox.h')
-rw-r--r--src/widgets/widgets/qcheckbox.h5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/widgets/widgets/qcheckbox.h b/src/widgets/widgets/qcheckbox.h
index e385dadbb8..54c2c3c796 100644
--- a/src/widgets/widgets/qcheckbox.h
+++ b/src/widgets/widgets/qcheckbox.h
@@ -36,11 +36,8 @@ public:
void setCheckState(Qt::CheckState state);
Q_SIGNALS:
-#if QT_VERSION < QT_VERSION_CHECK(7, 0, 0)
void stateChanged(int);
-#else
- void stateChanged(Qt::CheckState);
-#endif
+ void checkStateChanged(Qt::CheckState);
protected:
bool event(QEvent *e) override;