QSignalSpy: inline init() into its only caller

Following the verify() Extract Method refactorings, this function has
only one caller left, so it doesn't pull its weight anymore,
esp. considering that it'll be exported soon.

Task-number: QTBUG-123544
Change-Id: I1690b4b6e5a0e0c56fcc9c34544fca3b34e2f9a6
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
bb10
Marc Mutz 2024-03-21 17:37:04 +01:00
parent 2f39027232
commit fa5cb84069
1 changed files with 3 additions and 8 deletions

View File

@ -136,16 +136,11 @@ private:
{
if (!os.obj)
return;
init(os.obj, os.sig);
}
void init(const QObject *obj, QMetaMethod signal)
{
initArgs(signal, obj);
if (!connectToSignal(obj, signal.methodIndex()))
initArgs(os.sig, os.obj);
if (!connectToSignal(os.obj, os.sig.methodIndex()))
return;
sig = signal.methodSignature();
sig = os.sig.methodSignature();
}
bool connectToSignal(const QObject *sender, int sigIndex)