diff options
| author | Ahmad Samir <a.samirh78@gmail.com> | 2025-09-22 18:14:15 +0000 |
|---|---|---|
| committer | Ahmad Samir <a.samirh78@gmail.com> | 2025-09-26 20:06:40 +0000 |
| commit | 3b0da20d138866c6bb5af33bf5cb46ef803e18fb (patch) | |
| tree | 38247d68f5a2ff8d1a48c7fb7fdd9cc971e4b1bb /src/corelib/kernel/qobject.cpp | |
| parent | 253dadeb72b1e3caee46919d0b896c24efb10b91 (diff) | |
Revert "QObject: clarify what `method` is in string-based (dis)connect overloads"
This reverts commit 6f353fc17a3a6f1786359df36db209d6c5b0fa42.
As pointed out in code review, using SLOT() to find a Q_INVOKABLE method
isn't the intended behavior; it should only work with functions declared
as slots; pointed out by Thiago in code review.
Pick-to: 6.10 6.9 6.8 6.5
Change-Id: I000438b7901a8eb0392731564005bfdd85740c77
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/kernel/qobject.cpp')
| -rw-r--r-- | src/corelib/kernel/qobject.cpp | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/src/corelib/kernel/qobject.cpp b/src/corelib/kernel/qobject.cpp index fb4d8ab4b50..374741cb754 100644 --- a/src/corelib/kernel/qobject.cpp +++ b/src/corelib/kernel/qobject.cpp @@ -2968,12 +2968,6 @@ static inline void check_and_warn_compat(const QMetaObject *sender, const QMetaM Returns a handle to the connection that can be used to disconnect it later. - \a signal must be a member function decleared as a signal in \a sender. - - \a method must be a member function declared as a signal, slot, or - \l{Q_INVOKABLE}{invokable} in \a receiver, that is, functions registered - with the meta-object system. - You must use the \c SIGNAL() and \c SLOT() macros when specifying the \a signal and the \a method, for example: @@ -3261,13 +3255,6 @@ QMetaObject::Connection QObject::connect(const QObject *sender, const QMetaMetho \a receiver. Returns \c true if the connection is successfully broken; otherwise returns \c false. - \a signal, if not \nullptr, must be a member function decleared as a signal - in \a sender. - - \a method, if not \nullptr, must be a member function declared as a signal, - slot, or \l{Q_INVOKABLE}{invokable} in \a receiver, that is, functions - registered with the meta-object system. - A signal-slot connection is removed when either of the objects involved are destroyed. |
