From 06ed67d05cab821a79b9763fecf4c9094e41b595 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A5rten=20Nordheim?= Date: Thu, 5 Oct 2023 15:53:06 +0200 Subject: [PATCH] QNonContigByteDevice: Use PMF-style connect clang-format and the optimized SIGNAL/SLOT notation are not good friends. Change-Id: Id07936b4654e567b59af5a8b1d7baad000484931 Reviewed-by: Fabian Kosmale Reviewed-by: Mate Barany --- src/corelib/io/qnoncontiguousbytedevice.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/corelib/io/qnoncontiguousbytedevice.cpp b/src/corelib/io/qnoncontiguousbytedevice.cpp index 87fa6f02bd..283253eb02 100644 --- a/src/corelib/io/qnoncontiguousbytedevice.cpp +++ b/src/corelib/io/qnoncontiguousbytedevice.cpp @@ -106,8 +106,10 @@ QNonContiguousByteDeviceBufferImpl::QNonContiguousByteDeviceBufferImpl(QBuffer * byteArray = QByteArray::fromRawData(buffer->buffer().constData() + buffer->pos(), buffer->size() - buffer->pos()); arrayImpl = new QNonContiguousByteDeviceByteArrayImpl(&byteArray); arrayImpl->setParent(this); - connect(arrayImpl, SIGNAL(readyRead()), SIGNAL(readyRead())); - connect(arrayImpl, SIGNAL(readProgress(qint64,qint64)), SIGNAL(readProgress(qint64,qint64))); + connect(arrayImpl, &QNonContiguousByteDevice::readyRead, this, + &QNonContiguousByteDevice::readyRead); + connect(arrayImpl, &QNonContiguousByteDevice::readProgress, this, + &QNonContiguousByteDevice::readProgress); } QNonContiguousByteDeviceBufferImpl::~QNonContiguousByteDeviceBufferImpl() @@ -251,8 +253,10 @@ QNonContiguousByteDeviceIoDeviceImpl::QNonContiguousByteDeviceIoDeviceImpl(QIODe { device = d; initialPosition = d->pos(); - connect(device, SIGNAL(readyRead()), this, SIGNAL(readyRead()), Qt::QueuedConnection); - connect(device, SIGNAL(readChannelFinished()), this, SIGNAL(readyRead()), Qt::QueuedConnection); + connect(device, &QIODevice::readyRead, this, + &QNonContiguousByteDevice::readyRead); + connect(device, &QIODevice::readChannelFinished, this, + &QNonContiguousByteDevice::readyRead); } QNonContiguousByteDeviceIoDeviceImpl::~QNonContiguousByteDeviceIoDeviceImpl()