Port all connects
This is mostly all automatic from clazy, though it got confused by a few namespace issues.
This commit is contained in:
parent
13e03bde1d
commit
09a45da505
19 changed files with 188 additions and 188 deletions
|
@ -59,7 +59,7 @@ void TestCompositor::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -70,7 +70,7 @@ void TestCompositor::init()
|
|||
QVERIFY(connectedSpy.wait());
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy compositorSpy(®istry, SIGNAL(compositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy compositorSpy(®istry, &KWayland::Client::Registry::compositorAnnounced);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
registry.setup();
|
||||
|
@ -106,7 +106,7 @@ void TestCompositor::testDestroy()
|
|||
connect(m_connection, &ConnectionThread::connectionDied, m_compositor, &Compositor::destroy);
|
||||
QVERIFY(m_compositor->isValid());
|
||||
|
||||
QSignalSpy connectionDiedSpy(m_connection, SIGNAL(connectionDied()));
|
||||
QSignalSpy connectionDiedSpy(m_connection, &KWayland::Client::ConnectionThread::connectionDied);
|
||||
QVERIFY(connectionDiedSpy.isValid());
|
||||
delete m_display;
|
||||
m_display = nullptr;
|
||||
|
@ -123,7 +123,7 @@ void TestCompositor::testCast()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
Registry registry;
|
||||
QSignalSpy compositorSpy(®istry, SIGNAL(compositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy compositorSpy(®istry, &KWayland::Client::Registry::compositorAnnounced);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
registry.setup();
|
||||
|
|
|
@ -73,7 +73,7 @@ void TestDataDevice::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -89,11 +89,11 @@ void TestDataDevice::init()
|
|||
QVERIFY(m_queue->isValid());
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy dataDeviceManagerSpy(®istry, SIGNAL(dataDeviceManagerAnnounced(quint32,quint32)));
|
||||
QSignalSpy dataDeviceManagerSpy(®istry, &KWayland::Client::Registry::dataDeviceManagerAnnounced);
|
||||
QVERIFY(dataDeviceManagerSpy.isValid());
|
||||
QSignalSpy seatSpy(®istry, SIGNAL(seatAnnounced(quint32,quint32)));
|
||||
QSignalSpy seatSpy(®istry, &KWayland::Client::Registry::seatAnnounced);
|
||||
QVERIFY(seatSpy.isValid());
|
||||
QSignalSpy compositorSpy(®istry, SIGNAL(compositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy compositorSpy(®istry, &KWayland::Client::Registry::compositorAnnounced);
|
||||
QVERIFY(compositorSpy.isValid());
|
||||
QVERIFY(!registry.eventQueue());
|
||||
registry.setEventQueue(m_queue);
|
||||
|
@ -117,7 +117,7 @@ void TestDataDevice::init()
|
|||
m_seat = registry.createSeat(seatSpy.first().first().value<quint32>(),
|
||||
seatSpy.first().last().value<quint32>(), this);
|
||||
QVERIFY(m_seat->isValid());
|
||||
QSignalSpy pointerChangedSpy(m_seat, SIGNAL(hasPointerChanged(bool)));
|
||||
QSignalSpy pointerChangedSpy(m_seat, &KWayland::Client::Seat::hasPointerChanged);
|
||||
QVERIFY(pointerChangedSpy.isValid());
|
||||
QVERIFY(pointerChangedSpy.wait());
|
||||
|
||||
|
@ -164,7 +164,7 @@ void TestDataDevice::testCreate()
|
|||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
|
||||
QSignalSpy dataDeviceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataDeviceCreated(KWaylandServer::DataDeviceInterface*)));
|
||||
QSignalSpy dataDeviceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataDeviceCreated);
|
||||
QVERIFY(dataDeviceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataDevice> dataDevice(m_dataDeviceManager->getDataDevice(m_seat));
|
||||
|
@ -211,7 +211,7 @@ void TestDataDevice::testDrag()
|
|||
using namespace KWaylandServer;
|
||||
QScopedPointer<Pointer> pointer(m_seat->createPointer());
|
||||
|
||||
QSignalSpy dataDeviceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataDeviceCreated(KWaylandServer::DataDeviceInterface*)));
|
||||
QSignalSpy dataDeviceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataDeviceCreated);
|
||||
QVERIFY(dataDeviceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataDevice> dataDevice(m_dataDeviceManager->getDataDevice(m_seat));
|
||||
|
@ -222,7 +222,7 @@ void TestDataDevice::testDrag()
|
|||
auto deviceInterface = dataDeviceCreatedSpy.first().first().value<DataDeviceInterface*>();
|
||||
QVERIFY(deviceInterface);
|
||||
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataSourceCreated(KWaylandServer::DataSourceInterface*)));
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataSourceCreated);
|
||||
QVERIFY(dataDeviceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataSource> dataSource(m_dataDeviceManager->createDataSource());
|
||||
|
@ -233,7 +233,7 @@ void TestDataDevice::testDrag()
|
|||
auto sourceInterface = dataSourceCreatedSpy.first().first().value<DataSourceInterface*>();
|
||||
QVERIFY(sourceInterface);
|
||||
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(surfaceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<Surface> surface(m_compositor->createSurface());
|
||||
|
@ -244,7 +244,7 @@ void TestDataDevice::testDrag()
|
|||
auto surfaceInterface = surfaceCreatedSpy.first().first().value<SurfaceInterface*>();
|
||||
|
||||
// now we have all we need to start a drag operation
|
||||
QSignalSpy dragStartedSpy(deviceInterface, SIGNAL(dragStarted()));
|
||||
QSignalSpy dragStartedSpy(deviceInterface, &KWaylandServer::DataDeviceInterface::dragStarted);
|
||||
QVERIFY(dragStartedSpy.isValid());
|
||||
|
||||
// first we need to fake the pointer enter
|
||||
|
@ -294,7 +294,7 @@ void TestDataDevice::testDragInternally()
|
|||
using namespace KWaylandServer;
|
||||
QScopedPointer<Pointer> pointer(m_seat->createPointer());
|
||||
|
||||
QSignalSpy dataDeviceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataDeviceCreated(KWaylandServer::DataDeviceInterface*)));
|
||||
QSignalSpy dataDeviceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataDeviceCreated);
|
||||
QVERIFY(dataDeviceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataDevice> dataDevice(m_dataDeviceManager->getDataDevice(m_seat));
|
||||
|
@ -305,7 +305,7 @@ void TestDataDevice::testDragInternally()
|
|||
auto deviceInterface = dataDeviceCreatedSpy.first().first().value<DataDeviceInterface*>();
|
||||
QVERIFY(deviceInterface);
|
||||
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(surfaceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<Surface> surface(m_compositor->createSurface());
|
||||
|
@ -323,7 +323,7 @@ void TestDataDevice::testDragInternally()
|
|||
auto iconSurfaceInterface = surfaceCreatedSpy.last().first().value<SurfaceInterface*>();
|
||||
|
||||
// now we have all we need to start a drag operation
|
||||
QSignalSpy dragStartedSpy(deviceInterface, SIGNAL(dragStarted()));
|
||||
QSignalSpy dragStartedSpy(deviceInterface, &KWaylandServer::DataDeviceInterface::dragStarted);
|
||||
QVERIFY(dragStartedSpy.isValid());
|
||||
|
||||
// first we need to fake the pointer enter
|
||||
|
@ -366,7 +366,7 @@ void TestDataDevice::testSetSelection()
|
|||
using namespace KWaylandServer;
|
||||
QScopedPointer<Pointer> pointer(m_seat->createPointer());
|
||||
|
||||
QSignalSpy dataDeviceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataDeviceCreated(KWaylandServer::DataDeviceInterface*)));
|
||||
QSignalSpy dataDeviceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataDeviceCreated);
|
||||
QVERIFY(dataDeviceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataDevice> dataDevice(m_dataDeviceManager->getDataDevice(m_seat));
|
||||
|
@ -377,7 +377,7 @@ void TestDataDevice::testSetSelection()
|
|||
auto deviceInterface = dataDeviceCreatedSpy.first().first().value<DataDeviceInterface*>();
|
||||
QVERIFY(deviceInterface);
|
||||
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataSourceCreated(KWaylandServer::DataSourceInterface*)));
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataSourceCreated);
|
||||
QVERIFY(dataDeviceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataSource> dataSource(m_dataDeviceManager->createDataSource());
|
||||
|
@ -390,9 +390,9 @@ void TestDataDevice::testSetSelection()
|
|||
QVERIFY(sourceInterface);
|
||||
|
||||
// everything setup, now we can test setting the selection
|
||||
QSignalSpy selectionChangedSpy(deviceInterface, SIGNAL(selectionChanged(KWaylandServer::DataSourceInterface*)));
|
||||
QSignalSpy selectionChangedSpy(deviceInterface, &KWaylandServer::DataDeviceInterface::selectionChanged);
|
||||
QVERIFY(selectionChangedSpy.isValid());
|
||||
QSignalSpy selectionClearedSpy(deviceInterface, SIGNAL(selectionCleared()));
|
||||
QSignalSpy selectionClearedSpy(deviceInterface, &KWaylandServer::DataDeviceInterface::selectionCleared);
|
||||
QVERIFY(selectionClearedSpy.isValid());
|
||||
|
||||
QVERIFY(!deviceInterface->selection());
|
||||
|
@ -404,7 +404,7 @@ void TestDataDevice::testSetSelection()
|
|||
QCOMPARE(deviceInterface->selection(), sourceInterface);
|
||||
|
||||
// send selection to datadevice
|
||||
QSignalSpy selectionOfferedSpy(dataDevice.data(), SIGNAL(selectionOffered(KWayland::Client::DataOffer*)));
|
||||
QSignalSpy selectionOfferedSpy(dataDevice.data(), &KWayland::Client::DataDevice::selectionOffered);
|
||||
QVERIFY(selectionOfferedSpy.isValid());
|
||||
deviceInterface->sendSelection(deviceInterface->selection());
|
||||
QVERIFY(selectionOfferedSpy.wait());
|
||||
|
@ -415,7 +415,7 @@ void TestDataDevice::testSetSelection()
|
|||
QCOMPARE(dataOffer->offeredMimeTypes().first().name(), QStringLiteral("text/plain"));
|
||||
|
||||
// sending a new mimetype to the selection, should be announced in the offer
|
||||
QSignalSpy mimeTypeAddedSpy(dataOffer, SIGNAL(mimeTypeOffered(QString)));
|
||||
QSignalSpy mimeTypeAddedSpy(dataOffer, &KWayland::Client::DataOffer::mimeTypeOffered);
|
||||
QVERIFY(mimeTypeAddedSpy.isValid());
|
||||
dataSource->offer(QStringLiteral("text/html"));
|
||||
QVERIFY(mimeTypeAddedSpy.wait());
|
||||
|
@ -606,7 +606,7 @@ void TestDataDevice::testDestroy()
|
|||
connect(m_connection, &ConnectionThread::connectionDied, dataDevice.data(), &DataDevice::destroy);
|
||||
connect(m_connection, &ConnectionThread::connectionDied, m_queue, &EventQueue::destroy);
|
||||
|
||||
QSignalSpy connectionDiedSpy(m_connection, SIGNAL(connectionDied()));
|
||||
QSignalSpy connectionDiedSpy(m_connection, &KWayland::Client::ConnectionThread::connectionDied);
|
||||
QVERIFY(connectionDiedSpy.isValid());
|
||||
delete m_display;
|
||||
m_display = nullptr;
|
||||
|
|
|
@ -55,7 +55,7 @@ void TestDataSource::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -71,7 +71,7 @@ void TestDataSource::init()
|
|||
QVERIFY(m_queue->isValid());
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy dataDeviceManagerSpy(®istry, SIGNAL(dataDeviceManagerAnnounced(quint32,quint32)));
|
||||
QSignalSpy dataDeviceManagerSpy(®istry, &KWayland::Client::Registry::dataDeviceManagerAnnounced);
|
||||
QVERIFY(dataDeviceManagerSpy.isValid());
|
||||
QVERIFY(!registry.eventQueue());
|
||||
registry.setEventQueue(m_queue);
|
||||
|
@ -116,7 +116,7 @@ void TestDataSource::testOffer()
|
|||
using namespace KWaylandServer;
|
||||
|
||||
qRegisterMetaType<KWaylandServer::DataSourceInterface*>();
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataSourceCreated(KWaylandServer::DataSourceInterface*)));
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataSourceCreated);
|
||||
QVERIFY(dataSourceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataSource> dataSource(m_dataDeviceManager->createDataSource());
|
||||
|
@ -129,7 +129,7 @@ void TestDataSource::testOffer()
|
|||
QVERIFY(!serverDataSource.isNull());
|
||||
QCOMPARE(serverDataSource->mimeTypes().count(), 0);
|
||||
|
||||
QSignalSpy offeredSpy(serverDataSource.data(), SIGNAL(mimeTypeOffered(QString)));
|
||||
QSignalSpy offeredSpy(serverDataSource.data(), &KWaylandServer::AbstractDataSource::mimeTypeOffered);
|
||||
QVERIFY(offeredSpy.isValid());
|
||||
|
||||
const QString plain = QStringLiteral("text/plain");
|
||||
|
@ -174,13 +174,13 @@ void TestDataSource::testTargetAccepts()
|
|||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataSourceCreated(KWaylandServer::DataSourceInterface*)));
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataSourceCreated);
|
||||
QVERIFY(dataSourceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataSource> dataSource(m_dataDeviceManager->createDataSource());
|
||||
QVERIFY(dataSource->isValid());
|
||||
|
||||
QSignalSpy targetAcceptsSpy(dataSource.data(), SIGNAL(targetAccepts(QString)));
|
||||
QSignalSpy targetAcceptsSpy(dataSource.data(), &KWayland::Client::DataSource::targetAccepts);
|
||||
QVERIFY(targetAcceptsSpy.isValid());
|
||||
|
||||
QVERIFY(dataSourceCreatedSpy.wait());
|
||||
|
@ -199,12 +199,12 @@ void TestDataSource::testRequestSend()
|
|||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataSourceCreated(KWaylandServer::DataSourceInterface*)));
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataSourceCreated);
|
||||
QVERIFY(dataSourceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataSource> dataSource(m_dataDeviceManager->createDataSource());
|
||||
QVERIFY(dataSource->isValid());
|
||||
QSignalSpy sendRequestedSpy(dataSource.data(), SIGNAL(sendDataRequested(QString,qint32)));
|
||||
QSignalSpy sendRequestedSpy(dataSource.data(), &KWayland::Client::DataSource::sendDataRequested);
|
||||
QVERIFY(sendRequestedSpy.isValid());
|
||||
|
||||
const QString plain = QStringLiteral("text/plain");
|
||||
|
@ -230,12 +230,12 @@ void TestDataSource::testCancel()
|
|||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataSourceCreated(KWaylandServer::DataSourceInterface*)));
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataSourceCreated);
|
||||
QVERIFY(dataSourceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataSource> dataSource(m_dataDeviceManager->createDataSource());
|
||||
QVERIFY(dataSource->isValid());
|
||||
QSignalSpy cancelledSpy(dataSource.data(), SIGNAL(cancelled()));
|
||||
QSignalSpy cancelledSpy(dataSource.data(), &KWayland::Client::DataSource::cancelled);
|
||||
QVERIFY(cancelledSpy.isValid());
|
||||
|
||||
QVERIFY(dataSourceCreatedSpy.wait());
|
||||
|
@ -252,7 +252,7 @@ void TestDataSource::testServerGet()
|
|||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, SIGNAL(dataSourceCreated(KWaylandServer::DataSourceInterface*)));
|
||||
QSignalSpy dataSourceCreatedSpy(m_dataDeviceManagerInterface, &KWaylandServer::DataDeviceManagerInterface::dataSourceCreated);
|
||||
QVERIFY(dataSourceCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<DataSource> dataSource(m_dataDeviceManager->createDataSource());
|
||||
|
@ -277,7 +277,7 @@ void TestDataSource::testDestroy()
|
|||
connect(m_connection, &ConnectionThread::connectionDied, m_queue, &EventQueue::destroy);
|
||||
connect(m_connection, &ConnectionThread::connectionDied, dataSource.data(), &DataSource::destroy);
|
||||
|
||||
QSignalSpy connectionDiedSpy(m_connection, SIGNAL(connectionDied()));
|
||||
QSignalSpy connectionDiedSpy(m_connection, &KWayland::Client::ConnectionThread::connectionDied);
|
||||
QVERIFY(connectionDiedSpy.isValid());
|
||||
delete m_display;
|
||||
m_display = nullptr;
|
||||
|
|
|
@ -106,7 +106,7 @@ void TestVirtualDesktop::init()
|
|||
QSignalSpy plasmaVirtualDesktopManagementSpy(®istry, &Registry::plasmaVirtualDesktopManagementAnnounced);
|
||||
QVERIFY(plasmaVirtualDesktopManagementSpy.isValid());
|
||||
|
||||
QSignalSpy windowManagementSpy(®istry, SIGNAL(plasmaWindowManagementAnnounced(quint32,quint32)));
|
||||
QSignalSpy windowManagementSpy(®istry, &Registry::plasmaWindowManagementAnnounced);
|
||||
QVERIFY(windowManagementSpy.isValid());
|
||||
|
||||
QVERIFY(!registry.eventQueue());
|
||||
|
@ -131,13 +131,13 @@ void TestVirtualDesktop::init()
|
|||
QVERIFY(windowManagementSpy.wait());
|
||||
m_windowManagement = registry.createPlasmaWindowManagement(windowManagementSpy.first().first().value<quint32>(), windowManagementSpy.first().last().value<quint32>(), this);
|
||||
|
||||
QSignalSpy windowSpy(m_windowManagement, SIGNAL(windowCreated(KWayland::Client::PlasmaWindow*)));
|
||||
QSignalSpy windowSpy(m_windowManagement, &PlasmaWindowManagement::windowCreated);
|
||||
QVERIFY(windowSpy.isValid());
|
||||
m_windowInterface = m_windowManagementInterface->createWindow(this, QUuid::createUuid());
|
||||
m_windowInterface->setPid(1337);
|
||||
|
||||
QVERIFY(windowSpy.wait());
|
||||
m_window = windowSpy.first().first().value<KWayland::Client::PlasmaWindow *>();
|
||||
m_window = windowSpy.first().first().value<PlasmaWindow *>();
|
||||
}
|
||||
|
||||
void TestVirtualDesktop::cleanup()
|
||||
|
|
|
@ -135,7 +135,7 @@ void TestServerSideDecorationPalette::cleanup()
|
|||
|
||||
void TestServerSideDecorationPalette::testCreateAndSet()
|
||||
{
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
|
||||
QScopedPointer<KWayland::Client::Surface> surface(m_compositor->createSurface());
|
||||
|
|
|
@ -66,7 +66,7 @@ void TestShmPool::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -77,7 +77,7 @@ void TestShmPool::init()
|
|||
QVERIFY(connectedSpy.wait());
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy shmSpy(®istry, SIGNAL(shmAnnounced(quint32,quint32)));
|
||||
QSignalSpy shmSpy(®istry, &KWayland::Client::Registry::shmAnnounced);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
registry.setup();
|
||||
|
@ -215,7 +215,7 @@ void TestShmPool::testDestroy()
|
|||
// let's create one Buffer
|
||||
m_shmPool->getBuffer(QSize(10, 10), 8);
|
||||
|
||||
QSignalSpy connectionDiedSpy(m_connection, SIGNAL(connectionDied()));
|
||||
QSignalSpy connectionDiedSpy(m_connection, &KWayland::Client::ConnectionThread::connectionDied);
|
||||
QVERIFY(connectionDiedSpy.isValid());
|
||||
delete m_display;
|
||||
m_display = nullptr;
|
||||
|
|
|
@ -138,7 +138,7 @@ void TestAppmenu::cleanup()
|
|||
|
||||
void TestAppmenu::testCreateAndSet()
|
||||
{
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
|
||||
QScopedPointer<KWayland::Client::Surface> surface(m_compositor->createSurface());
|
||||
|
|
|
@ -136,14 +136,14 @@ void TestBlur::cleanup()
|
|||
|
||||
void TestBlur::testCreate()
|
||||
{
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
|
||||
QScopedPointer<KWayland::Client::Surface> surface(m_compositor->createSurface());
|
||||
QVERIFY(serverSurfaceCreated.wait());
|
||||
|
||||
auto serverSurface = serverSurfaceCreated.first().first().value<KWaylandServer::SurfaceInterface*>();
|
||||
QSignalSpy blurChanged(serverSurface, SIGNAL(blurChanged()));
|
||||
QSignalSpy blurChanged(serverSurface, &KWaylandServer::SurfaceInterface::blurChanged);
|
||||
|
||||
auto blur = m_blurManager->createBlur(surface.data(), surface.data());
|
||||
blur->setRegion(m_compositor->createRegion(QRegion(0, 0, 10, 20), nullptr));
|
||||
|
|
|
@ -70,7 +70,7 @@ void TestContrast::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -139,14 +139,14 @@ void TestContrast::cleanup()
|
|||
|
||||
void TestContrast::testCreate()
|
||||
{
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
|
||||
QScopedPointer<KWayland::Client::Surface> surface(m_compositor->createSurface());
|
||||
QVERIFY(serverSurfaceCreated.wait());
|
||||
|
||||
auto serverSurface = serverSurfaceCreated.first().first().value<KWaylandServer::SurfaceInterface*>();
|
||||
QSignalSpy contrastChanged(serverSurface, SIGNAL(contrastChanged()));
|
||||
QSignalSpy contrastChanged(serverSurface, &KWaylandServer::SurfaceInterface::contrastChanged);
|
||||
|
||||
auto contrast = m_contrastManager->createContrast(surface.data(), surface.data());
|
||||
contrast->setRegion(m_compositor->createRegion(QRegion(0, 0, 10, 20), nullptr));
|
||||
|
|
|
@ -87,7 +87,7 @@ void TestWaylandOutput::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -148,7 +148,7 @@ void TestWaylandOutput::testRegistry()
|
|||
QCOMPARE(physicalSizeChangedSpy.count(), 1);
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy announced(®istry, SIGNAL(outputAnnounced(quint32,quint32)));
|
||||
QSignalSpy announced(®istry, &KWayland::Client::Registry::outputAnnounced);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
registry.setup();
|
||||
|
@ -168,7 +168,7 @@ void TestWaylandOutput::testRegistry()
|
|||
QCOMPARE(output.subPixel(), KWayland::Client::Output::SubPixel::Unknown);
|
||||
QCOMPARE(output.transform(), KWayland::Client::Output::Transform::Normal);
|
||||
|
||||
QSignalSpy outputChanged(&output, SIGNAL(changed()));
|
||||
QSignalSpy outputChanged(&output, &KWayland::Client::Output::changed);
|
||||
QVERIFY(outputChanged.isValid());
|
||||
|
||||
auto o = registry.bindOutput(announced.first().first().value<quint32>(), announced.first().last().value<quint32>());
|
||||
|
@ -210,7 +210,7 @@ void TestWaylandOutput::testModeChanges()
|
|||
|
||||
using namespace KWayland::Client;
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy announced(®istry, SIGNAL(outputAnnounced(quint32,quint32)));
|
||||
QSignalSpy announced(®istry, &KWayland::Client::Registry::outputAnnounced);
|
||||
registry.setEventQueue(m_queue);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
|
@ -219,9 +219,9 @@ void TestWaylandOutput::testModeChanges()
|
|||
QVERIFY(announced.wait());
|
||||
|
||||
KWayland::Client::Output output;
|
||||
QSignalSpy outputChanged(&output, SIGNAL(changed()));
|
||||
QSignalSpy outputChanged(&output, &KWayland::Client::Output::changed);
|
||||
QVERIFY(outputChanged.isValid());
|
||||
QSignalSpy modeAddedSpy(&output, SIGNAL(modeAdded(KWayland::Client::Output::Mode)));
|
||||
QSignalSpy modeAddedSpy(&output, &KWayland::Client::Output::modeAdded);
|
||||
QVERIFY(modeAddedSpy.isValid());
|
||||
output.setup(registry.bindOutput(announced.first().first().value<quint32>(), announced.first().last().value<quint32>()));
|
||||
wl_display_flush(m_connection->display());
|
||||
|
@ -303,7 +303,7 @@ void TestWaylandOutput::testModeChanges()
|
|||
void TestWaylandOutput::testScaleChange()
|
||||
{
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy announced(®istry, SIGNAL(outputAnnounced(quint32,quint32)));
|
||||
QSignalSpy announced(®istry, &KWayland::Client::Registry::outputAnnounced);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
registry.setup();
|
||||
|
@ -311,7 +311,7 @@ void TestWaylandOutput::testScaleChange()
|
|||
QVERIFY(announced.wait());
|
||||
|
||||
KWayland::Client::Output output;
|
||||
QSignalSpy outputChanged(&output, SIGNAL(changed()));
|
||||
QSignalSpy outputChanged(&output, &KWayland::Client::Output::changed);
|
||||
QVERIFY(outputChanged.isValid());
|
||||
output.setup(registry.bindOutput(announced.first().first().value<quint32>(), announced.first().last().value<quint32>()));
|
||||
wl_display_flush(m_connection->display());
|
||||
|
@ -370,7 +370,7 @@ void TestWaylandOutput::testSubPixel()
|
|||
QCOMPARE(serverSubPixelChangedSpy.count(), 1);
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy announced(®istry, SIGNAL(outputAnnounced(quint32,quint32)));
|
||||
QSignalSpy announced(®istry, &KWayland::Client::Registry::outputAnnounced);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
registry.setup();
|
||||
|
@ -378,7 +378,7 @@ void TestWaylandOutput::testSubPixel()
|
|||
QVERIFY(announced.wait());
|
||||
|
||||
KWayland::Client::Output output;
|
||||
QSignalSpy outputChanged(&output, SIGNAL(changed()));
|
||||
QSignalSpy outputChanged(&output, &KWayland::Client::Output::changed);
|
||||
QVERIFY(outputChanged.isValid());
|
||||
output.setup(registry.bindOutput(announced.first().first().value<quint32>(), announced.first().last().value<quint32>()));
|
||||
wl_display_flush(m_connection->display());
|
||||
|
@ -431,7 +431,7 @@ void TestWaylandOutput::testTransform()
|
|||
QCOMPARE(serverTransformChangedSpy.count(), 1);
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy announced(®istry, SIGNAL(outputAnnounced(quint32,quint32)));
|
||||
QSignalSpy announced(®istry, &KWayland::Client::Registry::outputAnnounced);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
registry.setup();
|
||||
|
@ -439,7 +439,7 @@ void TestWaylandOutput::testTransform()
|
|||
QVERIFY(announced.wait());
|
||||
|
||||
KWayland::Client::Output *output = registry.createOutput(announced.first().first().value<quint32>(), announced.first().last().value<quint32>(), ®istry);
|
||||
QSignalSpy outputChanged(output, SIGNAL(changed()));
|
||||
QSignalSpy outputChanged(output, &KWayland::Client::Output::changed);
|
||||
QVERIFY(outputChanged.isValid());
|
||||
wl_display_flush(m_connection->display());
|
||||
if (outputChanged.isEmpty()) {
|
||||
|
|
|
@ -65,7 +65,7 @@ void TestRegion::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -81,7 +81,7 @@ void TestRegion::init()
|
|||
QVERIFY(m_queue->isValid());
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy compositorSpy(®istry, SIGNAL(compositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy compositorSpy(®istry, &KWayland::Client::Registry::compositorAnnounced);
|
||||
QVERIFY(compositorSpy.isValid());
|
||||
QVERIFY(!registry.eventQueue());
|
||||
registry.setEventQueue(m_queue);
|
||||
|
@ -122,7 +122,7 @@ void TestRegion::testCreate()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
QSignalSpy regionCreatedSpy(m_compositorInterface, SIGNAL(regionCreated(KWaylandServer::RegionInterface*)));
|
||||
QSignalSpy regionCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::regionCreated);
|
||||
QVERIFY(regionCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<Region> region(m_compositor->createRegion());
|
||||
|
@ -139,7 +139,7 @@ void TestRegion::testCreateWithRegion()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
QSignalSpy regionCreatedSpy(m_compositorInterface, SIGNAL(regionCreated(KWaylandServer::RegionInterface*)));
|
||||
QSignalSpy regionCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::regionCreated);
|
||||
QVERIFY(regionCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<Region> region(m_compositor->createRegion(QRegion(0, 0, 10, 20), nullptr));
|
||||
|
@ -156,7 +156,7 @@ void TestRegion::testCreateUniquePtr()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
QSignalSpy regionCreatedSpy(m_compositorInterface, SIGNAL(regionCreated(KWaylandServer::RegionInterface*)));
|
||||
QSignalSpy regionCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::regionCreated);
|
||||
QVERIFY(regionCreatedSpy.isValid());
|
||||
|
||||
std::unique_ptr<Region> region(m_compositor->createRegion(QRegion(0, 0, 10, 20)));
|
||||
|
@ -173,14 +173,14 @@ void TestRegion::testAdd()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
QSignalSpy regionCreatedSpy(m_compositorInterface, SIGNAL(regionCreated(KWaylandServer::RegionInterface*)));
|
||||
QSignalSpy regionCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::regionCreated);
|
||||
QVERIFY(regionCreatedSpy.isValid());
|
||||
|
||||
QScopedPointer<Region> region(m_compositor->createRegion());
|
||||
QVERIFY(regionCreatedSpy.wait());
|
||||
auto serverRegion = regionCreatedSpy.first().first().value<KWaylandServer::RegionInterface*>();
|
||||
|
||||
QSignalSpy regionChangedSpy(serverRegion, SIGNAL(regionChanged(QRegion)));
|
||||
QSignalSpy regionChangedSpy(serverRegion, &KWaylandServer::RegionInterface::regionChanged);
|
||||
QVERIFY(regionChangedSpy.isValid());
|
||||
|
||||
// adding a QRect
|
||||
|
@ -208,14 +208,14 @@ void TestRegion::testRemove()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
QSignalSpy regionCreatedSpy(m_compositorInterface, SIGNAL(regionCreated(KWaylandServer::RegionInterface*)));
|
||||
QSignalSpy regionCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::regionCreated);
|
||||
QVERIFY(regionCreatedSpy.isValid());
|
||||
|
||||
std::unique_ptr<Region> region(m_compositor->createRegion(QRegion(0, 0, 100, 200)));
|
||||
QVERIFY(regionCreatedSpy.wait());
|
||||
auto serverRegion = regionCreatedSpy.first().first().value<KWaylandServer::RegionInterface*>();
|
||||
|
||||
QSignalSpy regionChangedSpy(serverRegion, SIGNAL(regionChanged(QRegion)));
|
||||
QSignalSpy regionChangedSpy(serverRegion, &KWaylandServer::RegionInterface::regionChanged);
|
||||
QVERIFY(regionChangedSpy.isValid());
|
||||
|
||||
// subtract a QRect
|
||||
|
@ -250,7 +250,7 @@ void TestRegion::testDestroy()
|
|||
connect(m_connection, &ConnectionThread::connectionDied, m_queue, &EventQueue::destroy);
|
||||
QVERIFY(region->isValid());
|
||||
|
||||
QSignalSpy connectionDiedSpy(m_connection, SIGNAL(connectionDied()));
|
||||
QSignalSpy connectionDiedSpy(m_connection, &KWayland::Client::ConnectionThread::connectionDied);
|
||||
QVERIFY(connectionDiedSpy.isValid());
|
||||
delete m_display;
|
||||
m_display = nullptr;
|
||||
|
|
|
@ -137,7 +137,7 @@ void TestWaylandSeat::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -151,9 +151,9 @@ void TestWaylandSeat::init()
|
|||
m_queue->setup(m_connection);
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy compositorSpy(®istry, SIGNAL(compositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy seatSpy(®istry, SIGNAL(seatAnnounced(quint32,quint32)));
|
||||
QSignalSpy shmSpy(®istry, SIGNAL(shmAnnounced(quint32,quint32)));
|
||||
QSignalSpy compositorSpy(®istry, &KWayland::Client::Registry::compositorAnnounced);
|
||||
QSignalSpy seatSpy(®istry, &KWayland::Client::Registry::seatAnnounced);
|
||||
QSignalSpy shmSpy(®istry, &KWayland::Client::Registry::shmAnnounced);
|
||||
registry.setEventQueue(m_queue);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
|
@ -172,7 +172,7 @@ void TestWaylandSeat::init()
|
|||
QVERIFY(m_compositor->isValid());
|
||||
|
||||
m_seat = registry.createSeat(seatSpy.first().first().value<quint32>(), seatSpy.first().last().value<quint32>(), this);
|
||||
QSignalSpy nameSpy(m_seat, SIGNAL(nameChanged(QString)));
|
||||
QSignalSpy nameSpy(m_seat, &KWayland::Client::Seat::nameChanged);
|
||||
QVERIFY(nameSpy.wait());
|
||||
|
||||
m_shm = new KWayland::Client::ShmPool(this);
|
||||
|
@ -252,7 +252,7 @@ void TestWaylandSeat::testName()
|
|||
// no name set yet
|
||||
QCOMPARE(m_seat->name(), QStringLiteral("seat0"));
|
||||
|
||||
QSignalSpy spy(m_seat, SIGNAL(nameChanged(QString)));
|
||||
QSignalSpy spy(m_seat, &KWayland::Client::Seat::nameChanged);
|
||||
QVERIFY(spy.isValid());
|
||||
|
||||
const QString name = QStringLiteral("foobar");
|
||||
|
@ -289,11 +289,11 @@ void TestWaylandSeat::testCapabilities()
|
|||
QFETCH(bool, keyboard);
|
||||
QFETCH(bool, touch);
|
||||
|
||||
QSignalSpy pointerSpy(m_seat, SIGNAL(hasPointerChanged(bool)));
|
||||
QSignalSpy pointerSpy(m_seat, &KWayland::Client::Seat::hasPointerChanged);
|
||||
QVERIFY(pointerSpy.isValid());
|
||||
QSignalSpy keyboardSpy(m_seat, SIGNAL(hasKeyboardChanged(bool)));
|
||||
QSignalSpy keyboardSpy(m_seat, &KWayland::Client::Seat::hasKeyboardChanged);
|
||||
QVERIFY(keyboardSpy.isValid());
|
||||
QSignalSpy touchSpy(m_seat, SIGNAL(hasTouchChanged(bool)));
|
||||
QSignalSpy touchSpy(m_seat, &KWayland::Client::Seat::hasTouchChanged);
|
||||
QVERIFY(touchSpy.isValid());
|
||||
|
||||
m_seatInterface->setHasPointer(pointer);
|
||||
|
@ -333,12 +333,12 @@ void TestWaylandSeat::testPointer()
|
|||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
|
||||
QSignalSpy pointerSpy(m_seat, SIGNAL(hasPointerChanged(bool)));
|
||||
QSignalSpy pointerSpy(m_seat, &KWayland::Client::Seat::hasPointerChanged);
|
||||
QVERIFY(pointerSpy.isValid());
|
||||
m_seatInterface->setHasPointer(true);
|
||||
QVERIFY(pointerSpy.wait());
|
||||
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(surfaceCreatedSpy.isValid());
|
||||
Surface *s = m_compositor->createSurface(m_compositor);
|
||||
QVERIFY(surfaceCreatedSpy.wait());
|
||||
|
@ -363,7 +363,7 @@ void TestWaylandSeat::testPointer()
|
|||
QVERIFY(p->isValid());
|
||||
QScopedPointer<RelativePointer> relativePointer(m_relativePointerManager->createRelativePointer(p));
|
||||
QVERIFY(relativePointer->isValid());
|
||||
QSignalSpy pointerCreatedSpy(m_seatInterface, SIGNAL(pointerCreated(KWaylandServer::PointerInterface*)));
|
||||
QSignalSpy pointerCreatedSpy(m_seatInterface, &KWaylandServer::SeatInterface::pointerCreated);
|
||||
QVERIFY(pointerCreatedSpy.isValid());
|
||||
// once the pointer is created it should be set as the focused pointer
|
||||
QVERIFY(pointerCreatedSpy.wait());
|
||||
|
@ -381,19 +381,19 @@ void TestWaylandSeat::testPointer()
|
|||
QVERIFY(frameSpy.wait());
|
||||
QCOMPARE(frameSpy.count(), 2);
|
||||
|
||||
QSignalSpy enteredSpy(p, SIGNAL(entered(quint32,QPointF)));
|
||||
QSignalSpy enteredSpy(p, &KWayland::Client::Pointer::entered);
|
||||
QVERIFY(enteredSpy.isValid());
|
||||
|
||||
QSignalSpy leftSpy(p, SIGNAL(left(quint32)));
|
||||
QSignalSpy leftSpy(p, &KWayland::Client::Pointer::left);
|
||||
QVERIFY(leftSpy.isValid());
|
||||
|
||||
QSignalSpy motionSpy(p, SIGNAL(motion(QPointF,quint32)));
|
||||
QSignalSpy motionSpy(p, &KWayland::Client::Pointer::motion);
|
||||
QVERIFY(motionSpy.isValid());
|
||||
|
||||
QSignalSpy axisSpy(p, SIGNAL(axisChanged(quint32,KWayland::Client::Pointer::Axis,qreal)));
|
||||
QSignalSpy axisSpy(p, &KWayland::Client::Pointer::axisChanged);
|
||||
QVERIFY(axisSpy.isValid());
|
||||
|
||||
QSignalSpy buttonSpy(p, SIGNAL(buttonStateChanged(quint32,quint32,quint32,KWayland::Client::Pointer::ButtonState)));
|
||||
QSignalSpy buttonSpy(p, &KWayland::Client::Pointer::buttonStateChanged);
|
||||
QVERIFY(buttonSpy.isValid());
|
||||
|
||||
QSignalSpy relativeMotionSpy(relativePointer.data(), &RelativePointer::relativeMotion);
|
||||
|
@ -723,12 +723,12 @@ void TestWaylandSeat::testPointerButton()
|
|||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
|
||||
QSignalSpy pointerSpy(m_seat, SIGNAL(hasPointerChanged(bool)));
|
||||
QSignalSpy pointerSpy(m_seat, &KWayland::Client::Seat::hasPointerChanged);
|
||||
QVERIFY(pointerSpy.isValid());
|
||||
m_seatInterface->setHasPointer(true);
|
||||
QVERIFY(pointerSpy.wait());
|
||||
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(surfaceCreatedSpy.isValid());
|
||||
m_compositor->createSurface(m_compositor);
|
||||
QVERIFY(surfaceCreatedSpy.wait());
|
||||
|
@ -737,7 +737,7 @@ void TestWaylandSeat::testPointerButton()
|
|||
|
||||
QScopedPointer<Pointer> p(m_seat->createPointer());
|
||||
QVERIFY(p->isValid());
|
||||
QSignalSpy buttonChangedSpy(p.data(), SIGNAL(buttonStateChanged(quint32,quint32,quint32,KWayland::Client::Pointer::ButtonState)));
|
||||
QSignalSpy buttonChangedSpy(p.data(), &KWayland::Client::Pointer::buttonStateChanged);
|
||||
QVERIFY(buttonChangedSpy.isValid());
|
||||
wl_display_flush(m_connection->display());
|
||||
QCoreApplication::processEvents();
|
||||
|
@ -1320,12 +1320,12 @@ void TestWaylandSeat::testCursor()
|
|||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
|
||||
QSignalSpy pointerSpy(m_seat, SIGNAL(hasPointerChanged(bool)));
|
||||
QSignalSpy pointerSpy(m_seat, &KWayland::Client::Seat::hasPointerChanged);
|
||||
QVERIFY(pointerSpy.isValid());
|
||||
m_seatInterface->setHasPointer(true);
|
||||
QVERIFY(pointerSpy.wait());
|
||||
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(surfaceCreatedSpy.isValid());
|
||||
m_compositor->createSurface(m_compositor);
|
||||
QVERIFY(surfaceCreatedSpy.wait());
|
||||
|
@ -1337,7 +1337,7 @@ void TestWaylandSeat::testCursor()
|
|||
wl_display_flush(m_connection->display());
|
||||
QCoreApplication::processEvents();
|
||||
|
||||
QSignalSpy enteredSpy(p.data(), SIGNAL(entered(quint32,QPointF)));
|
||||
QSignalSpy enteredSpy(p.data(), &KWayland::Client::Pointer::entered);
|
||||
QVERIFY(enteredSpy.isValid());
|
||||
|
||||
m_seatInterface->setPointerPos(QPoint(20, 18));
|
||||
|
@ -1349,7 +1349,7 @@ void TestWaylandSeat::testCursor()
|
|||
QVERIFY(m_seatInterface->focusedPointer());
|
||||
QVERIFY(!m_seatInterface->focusedPointer()->cursor());
|
||||
|
||||
QSignalSpy cursorChangedSpy(m_seatInterface->focusedPointer(), SIGNAL(cursorChanged()));
|
||||
QSignalSpy cursorChangedSpy(m_seatInterface->focusedPointer(), &KWaylandServer::PointerInterface::cursorChanged);
|
||||
QVERIFY(cursorChangedSpy.isValid());
|
||||
// just remove the pointer
|
||||
p->setCursor(nullptr);
|
||||
|
@ -1362,13 +1362,13 @@ void TestWaylandSeat::testCursor()
|
|||
QCOMPARE(cursor->enteredSerial(), serial);
|
||||
QCOMPARE(cursor->pointer(), m_seatInterface->focusedPointer());
|
||||
|
||||
QSignalSpy hotspotChangedSpy(cursor, SIGNAL(hotspotChanged()));
|
||||
QSignalSpy hotspotChangedSpy(cursor, &KWaylandServer::Cursor::hotspotChanged);
|
||||
QVERIFY(hotspotChangedSpy.isValid());
|
||||
QSignalSpy surfaceChangedSpy(cursor, SIGNAL(surfaceChanged()));
|
||||
QSignalSpy surfaceChangedSpy(cursor, &KWaylandServer::Cursor::surfaceChanged);
|
||||
QVERIFY(surfaceChangedSpy.isValid());
|
||||
QSignalSpy enteredSerialChangedSpy(cursor, SIGNAL(enteredSerialChanged()));
|
||||
QSignalSpy enteredSerialChangedSpy(cursor, &KWaylandServer::Cursor::enteredSerialChanged);
|
||||
QVERIFY(enteredSerialChangedSpy.isValid());
|
||||
QSignalSpy changedSpy(cursor, SIGNAL(changed()));
|
||||
QSignalSpy changedSpy(cursor, &KWaylandServer::Cursor::changed);
|
||||
QVERIFY(changedSpy.isValid());
|
||||
|
||||
// test changing hotspot
|
||||
|
@ -1484,7 +1484,7 @@ void TestWaylandSeat::testKeyboard()
|
|||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
|
||||
QSignalSpy keyboardSpy(m_seat, SIGNAL(hasKeyboardChanged(bool)));
|
||||
QSignalSpy keyboardSpy(m_seat, &KWayland::Client::Seat::hasKeyboardChanged);
|
||||
QVERIFY(keyboardSpy.isValid());
|
||||
m_seatInterface->setHasKeyboard(true);
|
||||
QVERIFY(keyboardSpy.wait());
|
||||
|
@ -1493,7 +1493,7 @@ void TestWaylandSeat::testKeyboard()
|
|||
m_seatInterface->keyboard()->updateModifiers(4, 3, 2, 1);
|
||||
|
||||
// create the surface
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(surfaceCreatedSpy.isValid());
|
||||
Surface *s = m_compositor->createSurface(m_compositor);
|
||||
QVERIFY(surfaceCreatedSpy.wait());
|
||||
|
@ -1539,10 +1539,10 @@ void TestWaylandSeat::testKeyboard()
|
|||
m_seatInterface->setTimestamp(3);
|
||||
m_seatInterface->keyboard()->keyPressed(KEY_E);
|
||||
|
||||
QSignalSpy modifierSpy(keyboard, SIGNAL(modifiersChanged(quint32,quint32,quint32,quint32)));
|
||||
QSignalSpy modifierSpy(keyboard, &KWayland::Client::Keyboard::modifiersChanged);
|
||||
QVERIFY(modifierSpy.isValid());
|
||||
|
||||
QSignalSpy enteredSpy(keyboard, SIGNAL(entered(quint32)));
|
||||
QSignalSpy enteredSpy(keyboard, &KWayland::Client::Keyboard::entered);
|
||||
QVERIFY(enteredSpy.isValid());
|
||||
m_seatInterface->setFocusedKeyboardSurface(serverSurface);
|
||||
QCOMPARE(m_seatInterface->focusedKeyboardSurface(), serverSurface);
|
||||
|
@ -1559,7 +1559,7 @@ void TestWaylandSeat::testKeyboard()
|
|||
// TODO: get through API
|
||||
QCOMPARE(enteredSpy.first().first().value<quint32>(), m_display->serial() - 1);
|
||||
|
||||
QSignalSpy keyChangedSpy(keyboard, SIGNAL(keyChanged(quint32,KWayland::Client::Keyboard::KeyState,quint32)));
|
||||
QSignalSpy keyChangedSpy(keyboard, &KWayland::Client::Keyboard::keyChanged);
|
||||
QVERIFY(keyChangedSpy.isValid());
|
||||
|
||||
m_seatInterface->setTimestamp(4);
|
||||
|
@ -1618,7 +1618,7 @@ void TestWaylandSeat::testKeyboard()
|
|||
QCOMPARE(modifierSpy.last().at(2).value<quint32>(), quint32(3));
|
||||
QCOMPARE(modifierSpy.last().at(3).value<quint32>(), quint32(4));
|
||||
|
||||
QSignalSpy leftSpy(keyboard, SIGNAL(left(quint32)));
|
||||
QSignalSpy leftSpy(keyboard, &KWayland::Client::Keyboard::left);
|
||||
QVERIFY(leftSpy.isValid());
|
||||
m_seatInterface->setFocusedKeyboardSurface(nullptr);
|
||||
QVERIFY(!m_seatInterface->focusedKeyboardSurface());
|
||||
|
@ -1665,7 +1665,7 @@ void TestWaylandSeat::testCast()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
Registry registry;
|
||||
QSignalSpy seatSpy(®istry, SIGNAL(seatAnnounced(quint32,quint32)));
|
||||
QSignalSpy seatSpy(®istry, &KWayland::Client::Registry::seatAnnounced);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
registry.setup();
|
||||
|
@ -1686,21 +1686,21 @@ void TestWaylandSeat::testCast()
|
|||
void TestWaylandSeat::testDestroy()
|
||||
{
|
||||
using namespace KWayland::Client;
|
||||
QSignalSpy keyboardSpy(m_seat, SIGNAL(hasKeyboardChanged(bool)));
|
||||
QSignalSpy keyboardSpy(m_seat, &KWayland::Client::Seat::hasKeyboardChanged);
|
||||
QVERIFY(keyboardSpy.isValid());
|
||||
m_seatInterface->setHasKeyboard(true);
|
||||
QVERIFY(keyboardSpy.wait());
|
||||
Keyboard *k = m_seat->createKeyboard(m_seat);
|
||||
QVERIFY(k->isValid());
|
||||
|
||||
QSignalSpy pointerSpy(m_seat, SIGNAL(hasPointerChanged(bool)));
|
||||
QSignalSpy pointerSpy(m_seat, &KWayland::Client::Seat::hasPointerChanged);
|
||||
QVERIFY(pointerSpy.isValid());
|
||||
m_seatInterface->setHasPointer(true);
|
||||
QVERIFY(pointerSpy.wait());
|
||||
Pointer *p = m_seat->createPointer(m_seat);
|
||||
QVERIFY(p->isValid());
|
||||
|
||||
QSignalSpy touchSpy(m_seat, SIGNAL(hasTouchChanged(bool)));
|
||||
QSignalSpy touchSpy(m_seat, &KWayland::Client::Seat::hasTouchChanged);
|
||||
QVERIFY(touchSpy.isValid());
|
||||
m_seatInterface->setHasTouch(true);
|
||||
QVERIFY(touchSpy.wait());
|
||||
|
@ -1717,7 +1717,7 @@ void TestWaylandSeat::testDestroy()
|
|||
connect(m_connection, &ConnectionThread::connectionDied, m_queue, &EventQueue::destroy);
|
||||
QVERIFY(m_seat->isValid());
|
||||
|
||||
QSignalSpy connectionDiedSpy(m_connection, SIGNAL(connectionDied()));
|
||||
QSignalSpy connectionDiedSpy(m_connection, &KWayland::Client::ConnectionThread::connectionDied);
|
||||
QVERIFY(connectionDiedSpy.isValid());
|
||||
delete m_display;
|
||||
m_display = nullptr;
|
||||
|
@ -1747,7 +1747,7 @@ void TestWaylandSeat::testSelection()
|
|||
using namespace KWaylandServer;
|
||||
QScopedPointer<DataDeviceManagerInterface> ddmi(new DataDeviceManagerInterface(m_display));
|
||||
Registry registry;
|
||||
QSignalSpy dataDeviceManagerSpy(®istry, SIGNAL(dataDeviceManagerAnnounced(quint32,quint32)));
|
||||
QSignalSpy dataDeviceManagerSpy(®istry, &KWayland::Client::Registry::dataDeviceManagerAnnounced);
|
||||
QVERIFY(dataDeviceManagerSpy.isValid());
|
||||
m_seatInterface->setHasKeyboard(true);
|
||||
registry.setEventQueue(m_queue);
|
||||
|
@ -1762,12 +1762,12 @@ void TestWaylandSeat::testSelection()
|
|||
|
||||
QScopedPointer<DataDevice> dd1(ddm->getDataDevice(m_seat));
|
||||
QVERIFY(dd1->isValid());
|
||||
QSignalSpy selectionSpy(dd1.data(), SIGNAL(selectionOffered(KWayland::Client::DataOffer*)));
|
||||
QSignalSpy selectionSpy(dd1.data(), &KWayland::Client::DataDevice::selectionOffered);
|
||||
QVERIFY(selectionSpy.isValid());
|
||||
QSignalSpy selectionClearedSpy(dd1.data(), SIGNAL(selectionCleared()));
|
||||
QSignalSpy selectionClearedSpy(dd1.data(), &KWayland::Client::DataDevice::selectionCleared);
|
||||
QVERIFY(selectionClearedSpy.isValid());
|
||||
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(surfaceCreatedSpy.isValid());
|
||||
QScopedPointer<Surface> surface(m_compositor->createSurface());
|
||||
QVERIFY(surface->isValid());
|
||||
|
@ -1950,13 +1950,13 @@ void TestWaylandSeat::testTouch()
|
|||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
|
||||
QSignalSpy touchSpy(m_seat, SIGNAL(hasTouchChanged(bool)));
|
||||
QSignalSpy touchSpy(m_seat, &KWayland::Client::Seat::hasTouchChanged);
|
||||
QVERIFY(touchSpy.isValid());
|
||||
m_seatInterface->setHasTouch(true);
|
||||
QVERIFY(touchSpy.wait());
|
||||
|
||||
// create the surface
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(surfaceCreatedSpy.isValid());
|
||||
Surface *s = m_compositor->createSurface(m_compositor);
|
||||
QVERIFY(surfaceCreatedSpy.wait());
|
||||
|
@ -1968,7 +1968,7 @@ void TestWaylandSeat::testTouch()
|
|||
QCOMPARE(m_seatInterface->focusedTouchSurface(), serverSurface);
|
||||
QVERIFY(!m_seatInterface->focusedTouch());
|
||||
|
||||
QSignalSpy touchCreatedSpy(m_seatInterface, SIGNAL(touchCreated(KWaylandServer::TouchInterface*)));
|
||||
QSignalSpy touchCreatedSpy(m_seatInterface, &KWaylandServer::SeatInterface::touchCreated);
|
||||
QVERIFY(touchCreatedSpy.isValid());
|
||||
Touch *touch = m_seat->createTouch(m_seat);
|
||||
QVERIFY(touch->isValid());
|
||||
|
@ -1977,19 +1977,19 @@ void TestWaylandSeat::testTouch()
|
|||
QVERIFY(serverTouch);
|
||||
QCOMPARE(touchCreatedSpy.first().first().value<KWaylandServer::TouchInterface*>(), m_seatInterface->focusedTouch());
|
||||
|
||||
QSignalSpy sequenceStartedSpy(touch, SIGNAL(sequenceStarted(KWayland::Client::TouchPoint*)));
|
||||
QSignalSpy sequenceStartedSpy(touch, &KWayland::Client::Touch::sequenceStarted);
|
||||
QVERIFY(sequenceStartedSpy.isValid());
|
||||
QSignalSpy sequenceEndedSpy(touch, SIGNAL(sequenceEnded()));
|
||||
QSignalSpy sequenceEndedSpy(touch, &KWayland::Client::Touch::sequenceEnded);
|
||||
QVERIFY(sequenceEndedSpy.isValid());
|
||||
QSignalSpy sequenceCanceledSpy(touch, SIGNAL(sequenceCanceled()));
|
||||
QSignalSpy sequenceCanceledSpy(touch, &KWayland::Client::Touch::sequenceCanceled);
|
||||
QVERIFY(sequenceCanceledSpy.isValid());
|
||||
QSignalSpy frameEndedSpy(touch, SIGNAL(frameEnded()));
|
||||
QSignalSpy frameEndedSpy(touch, &KWayland::Client::Touch::frameEnded);
|
||||
QVERIFY(frameEndedSpy.isValid());
|
||||
QSignalSpy pointAddedSpy(touch, SIGNAL(pointAdded(KWayland::Client::TouchPoint*)));
|
||||
QSignalSpy pointAddedSpy(touch, &KWayland::Client::Touch::pointAdded);
|
||||
QVERIFY(pointAddedSpy.isValid());
|
||||
QSignalSpy pointMovedSpy(touch, SIGNAL(pointMoved(KWayland::Client::TouchPoint*)));
|
||||
QSignalSpy pointMovedSpy(touch, &KWayland::Client::Touch::pointMoved);
|
||||
QVERIFY(pointMovedSpy.isValid());
|
||||
QSignalSpy pointRemovedSpy(touch, SIGNAL(pointRemoved(KWayland::Client::TouchPoint*)));
|
||||
QSignalSpy pointRemovedSpy(touch, &KWayland::Client::Touch::pointRemoved);
|
||||
QVERIFY(pointRemovedSpy.isValid());
|
||||
|
||||
// try a few things
|
||||
|
@ -2236,7 +2236,7 @@ void TestWaylandSeat::testKeymap()
|
|||
QScopedPointer<Keyboard> keyboard(m_seat->createKeyboard());
|
||||
|
||||
// create surface
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(surfaceCreatedSpy.isValid());
|
||||
QScopedPointer<Surface> surface(m_compositor->createSurface());
|
||||
QVERIFY(surface->isValid());
|
||||
|
|
|
@ -67,7 +67,7 @@ void TestSlide::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -136,14 +136,14 @@ void TestSlide::cleanup()
|
|||
|
||||
void TestSlide::testCreate()
|
||||
{
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
|
||||
QScopedPointer<KWayland::Client::Surface> surface(m_compositor->createSurface());
|
||||
QVERIFY(serverSurfaceCreated.wait());
|
||||
|
||||
auto serverSurface = serverSurfaceCreated.first().first().value<KWaylandServer::SurfaceInterface*>();
|
||||
QSignalSpy slideChanged(serverSurface, SIGNAL(slideOnShowHideChanged()));
|
||||
QSignalSpy slideChanged(serverSurface, &KWaylandServer::SurfaceInterface::slideOnShowHideChanged);
|
||||
|
||||
auto slide = m_slideManager->createSlide(surface.data(), surface.data());
|
||||
slide->setLocation(KWayland::Client::Slide::Location::Top);
|
||||
|
|
|
@ -58,7 +58,7 @@ void TestSubCompositor::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -74,7 +74,7 @@ void TestSubCompositor::init()
|
|||
QVERIFY(m_queue->isValid());
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy subCompositorSpy(®istry, SIGNAL(subCompositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy subCompositorSpy(®istry, &KWayland::Client::Registry::subCompositorAnnounced);
|
||||
QVERIFY(subCompositorSpy.isValid());
|
||||
QVERIFY(!registry.eventQueue());
|
||||
registry.setEventQueue(m_queue);
|
||||
|
@ -120,7 +120,7 @@ void TestSubCompositor::testDestroy()
|
|||
connect(m_connection, &ConnectionThread::connectionDied, m_queue, &EventQueue::destroy);
|
||||
QVERIFY(m_subCompositor->isValid());
|
||||
|
||||
QSignalSpy connectionDiedSpy(m_connection, SIGNAL(connectionDied()));
|
||||
QSignalSpy connectionDiedSpy(m_connection, &KWayland::Client::ConnectionThread::connectionDied);
|
||||
QVERIFY(connectionDiedSpy.isValid());
|
||||
delete m_display;
|
||||
m_display = nullptr;
|
||||
|
@ -137,7 +137,7 @@ void TestSubCompositor::testCast()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
Registry registry;
|
||||
QSignalSpy subCompositorSpy(®istry, SIGNAL(subCompositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy subCompositorSpy(®istry, &KWayland::Client::Registry::subCompositorAnnounced);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
registry.setup();
|
||||
|
|
|
@ -91,7 +91,7 @@ void TestSubSurface::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -107,9 +107,9 @@ void TestSubSurface::init()
|
|||
QVERIFY(m_queue->isValid());
|
||||
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy compositorSpy(®istry, SIGNAL(compositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy compositorSpy(®istry, &KWayland::Client::Registry::compositorAnnounced);
|
||||
QVERIFY(compositorSpy.isValid());
|
||||
QSignalSpy subCompositorSpy(®istry, SIGNAL(subCompositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy subCompositorSpy(®istry, &KWayland::Client::Registry::subCompositorAnnounced);
|
||||
QVERIFY(subCompositorSpy.isValid());
|
||||
QVERIFY(!registry.eventQueue());
|
||||
registry.setEventQueue(m_queue);
|
||||
|
@ -169,7 +169,7 @@ void TestSubSurface::testCreate()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy surfaceCreatedSpy(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(surfaceCreatedSpy.isValid());
|
||||
|
||||
// create two Surfaces
|
||||
|
@ -184,7 +184,7 @@ void TestSubSurface::testCreate()
|
|||
SurfaceInterface *serverParentSurface = surfaceCreatedSpy.first().first().value<KWaylandServer::SurfaceInterface*>();
|
||||
QVERIFY(serverParentSurface);
|
||||
|
||||
QSignalSpy subSurfaceCreatedSpy(m_subcompositorInterface, SIGNAL(subSurfaceCreated(KWaylandServer::SubSurfaceInterface*)));
|
||||
QSignalSpy subSurfaceCreatedSpy(m_subcompositorInterface, &KWaylandServer::SubCompositorInterface::subSurfaceCreated);
|
||||
QVERIFY(subSurfaceCreatedSpy.isValid());
|
||||
|
||||
// create subSurface for surface of parent
|
||||
|
@ -209,7 +209,7 @@ void TestSubSurface::testCreate()
|
|||
QCOMPARE(serverParentSurface->childSubSurfaces().first(), serverSubSurface);
|
||||
|
||||
// and let's destroy it again
|
||||
QSignalSpy destroyedSpy(serverSubSurface, SIGNAL(destroyed(QObject*)));
|
||||
QSignalSpy destroyedSpy(serverSubSurface, &QObject::destroyed);
|
||||
QVERIFY(destroyedSpy.isValid());
|
||||
subSurface.reset();
|
||||
QVERIFY(destroyedSpy.wait());
|
||||
|
@ -236,7 +236,7 @@ void TestSubSurface::testMode()
|
|||
QScopedPointer<Surface> surface(m_compositor->createSurface());
|
||||
QScopedPointer<Surface> parent(m_compositor->createSurface());
|
||||
|
||||
QSignalSpy subSurfaceCreatedSpy(m_subcompositorInterface, SIGNAL(subSurfaceCreated(KWaylandServer::SubSurfaceInterface*)));
|
||||
QSignalSpy subSurfaceCreatedSpy(m_subcompositorInterface, &KWaylandServer::SubCompositorInterface::subSurfaceCreated);
|
||||
QVERIFY(subSurfaceCreatedSpy.isValid());
|
||||
|
||||
// create the SubSurface for surface of parent
|
||||
|
@ -250,7 +250,7 @@ void TestSubSurface::testMode()
|
|||
QCOMPARE(serverSubSurface->mode(), SubSurfaceInterface::Mode::Synchronized);
|
||||
|
||||
// verify that we can change to desynchronized
|
||||
QSignalSpy modeChangedSpy(serverSubSurface, SIGNAL(modeChanged(KWaylandServer::SubSurfaceInterface::Mode)));
|
||||
QSignalSpy modeChangedSpy(serverSubSurface, &KWaylandServer::SubSurfaceInterface::modeChanged);
|
||||
QVERIFY(modeChangedSpy.isValid());
|
||||
|
||||
subSurface->setMode(SubSurface::Mode::Desynchronized);
|
||||
|
@ -292,7 +292,7 @@ void TestSubSurface::testPosition()
|
|||
QScopedPointer<Surface> surface(m_compositor->createSurface());
|
||||
QScopedPointer<Surface> parent(m_compositor->createSurface());
|
||||
|
||||
QSignalSpy subSurfaceCreatedSpy(m_subcompositorInterface, SIGNAL(subSurfaceCreated(KWaylandServer::SubSurfaceInterface*)));
|
||||
QSignalSpy subSurfaceCreatedSpy(m_subcompositorInterface, &KWaylandServer::SubCompositorInterface::subSurfaceCreated);
|
||||
QVERIFY(subSurfaceCreatedSpy.isValid());
|
||||
|
||||
// create the SubSurface for surface of parent
|
||||
|
@ -313,7 +313,7 @@ void TestSubSurface::testPosition()
|
|||
QCOMPARE(subSurface->position(), QPoint());
|
||||
QCOMPARE(serverSubSurface->position(), QPoint());
|
||||
|
||||
QSignalSpy positionChangedSpy(serverSubSurface, SIGNAL(positionChanged(QPoint)));
|
||||
QSignalSpy positionChangedSpy(serverSubSurface, &KWaylandServer::SubSurfaceInterface::positionChanged);
|
||||
QVERIFY(positionChangedSpy.isValid());
|
||||
|
||||
// changing the position should not trigger a direct update on server side
|
||||
|
@ -351,7 +351,7 @@ void TestSubSurface::testPlaceAbove()
|
|||
QScopedPointer<Surface> surface3(m_compositor->createSurface());
|
||||
QScopedPointer<Surface> parent(m_compositor->createSurface());
|
||||
|
||||
QSignalSpy subSurfaceCreatedSpy(m_subcompositorInterface, SIGNAL(subSurfaceCreated(KWaylandServer::SubSurfaceInterface*)));
|
||||
QSignalSpy subSurfaceCreatedSpy(m_subcompositorInterface, &KWaylandServer::SubCompositorInterface::subSurfaceCreated);
|
||||
QVERIFY(subSurfaceCreatedSpy.isValid());
|
||||
|
||||
// create the SubSurfaces for surface of parent
|
||||
|
@ -452,7 +452,7 @@ void TestSubSurface::testPlaceBelow()
|
|||
QScopedPointer<Surface> surface3(m_compositor->createSurface());
|
||||
QScopedPointer<Surface> parent(m_compositor->createSurface());
|
||||
|
||||
QSignalSpy subSurfaceCreatedSpy(m_subcompositorInterface, SIGNAL(subSurfaceCreated(KWaylandServer::SubSurfaceInterface*)));
|
||||
QSignalSpy subSurfaceCreatedSpy(m_subcompositorInterface, &KWaylandServer::SubCompositorInterface::subSurfaceCreated);
|
||||
QVERIFY(subSurfaceCreatedSpy.isValid());
|
||||
|
||||
// create the SubSurfaces for surface of parent
|
||||
|
@ -562,7 +562,7 @@ void TestSubSurface::testDestroy()
|
|||
connect(m_connection, &ConnectionThread::connectionDied, subSurface.data(), &SubSurface::destroy);
|
||||
QVERIFY(subSurface->isValid());
|
||||
|
||||
QSignalSpy connectionDiedSpy(m_connection, SIGNAL(connectionDied()));
|
||||
QSignalSpy connectionDiedSpy(m_connection, &KWayland::Client::ConnectionThread::connectionDied);
|
||||
QVERIFY(connectionDiedSpy.isValid());
|
||||
delete m_display;
|
||||
m_display = nullptr;
|
||||
|
|
|
@ -96,7 +96,7 @@ void TestWaylandSurface::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -121,9 +121,9 @@ void TestWaylandSurface::init()
|
|||
|
||||
KWayland::Client::Registry registry;
|
||||
registry.setEventQueue(m_queue);
|
||||
QSignalSpy compositorSpy(®istry, SIGNAL(compositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy shmSpy(®istry, SIGNAL(shmAnnounced(quint32,quint32)));
|
||||
QSignalSpy allAnnounced(®istry, SIGNAL(interfacesAnnounced()));
|
||||
QSignalSpy compositorSpy(®istry, &KWayland::Client::Registry::compositorAnnounced);
|
||||
QSignalSpy shmSpy(®istry, &KWayland::Client::Registry::shmAnnounced);
|
||||
QSignalSpy allAnnounced(®istry, &KWayland::Client::Registry::interfacesAnnounced);
|
||||
QVERIFY(allAnnounced.isValid());
|
||||
QVERIFY(shmSpy.isValid());
|
||||
registry.create(m_connection->display());
|
||||
|
@ -179,7 +179,7 @@ void TestWaylandSurface::cleanup()
|
|||
|
||||
void TestWaylandSurface::testStaticAccessor()
|
||||
{
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
|
||||
QVERIFY(!KWaylandServer::SurfaceInterface::get(nullptr));
|
||||
|
@ -197,7 +197,7 @@ void TestWaylandSurface::testStaticAccessor()
|
|||
QCOMPARE(KWaylandServer::SurfaceInterface::get(serverSurface1->id(), serverSurface1->client()), serverSurface1);
|
||||
|
||||
QVERIFY(!s1->size().isValid());
|
||||
QSignalSpy sizeChangedSpy(s1, SIGNAL(sizeChanged(QSize)));
|
||||
QSignalSpy sizeChangedSpy(s1, &KWayland::Client::Surface::sizeChanged);
|
||||
QVERIFY(sizeChangedSpy.isValid());
|
||||
const QSize testSize(200, 300);
|
||||
s1->setSize(testSize);
|
||||
|
@ -245,7 +245,7 @@ void TestWaylandSurface::testStaticAccessor()
|
|||
|
||||
void TestWaylandSurface::testDamage()
|
||||
{
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
KWayland::Client::Surface *s = m_compositor->createSurface();
|
||||
s->setScale(2);
|
||||
|
@ -255,8 +255,8 @@ void TestWaylandSurface::testDamage()
|
|||
QCOMPARE(serverSurface->damage(), QRegion());
|
||||
QVERIFY(!serverSurface->isMapped());
|
||||
|
||||
QSignalSpy committedSpy(serverSurface, SIGNAL(committed()));
|
||||
QSignalSpy damageSpy(serverSurface, SIGNAL(damaged(QRegion)));
|
||||
QSignalSpy committedSpy(serverSurface, &KWaylandServer::SurfaceInterface::committed);
|
||||
QSignalSpy damageSpy(serverSurface, &KWaylandServer::SurfaceInterface::damaged);
|
||||
QVERIFY(damageSpy.isValid());
|
||||
|
||||
// send damage without a buffer
|
||||
|
@ -334,17 +334,17 @@ void TestWaylandSurface::testDamage()
|
|||
|
||||
void TestWaylandSurface::testFrameCallback()
|
||||
{
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
KWayland::Client::Surface *s = m_compositor->createSurface();
|
||||
QVERIFY(serverSurfaceCreated.wait());
|
||||
KWaylandServer::SurfaceInterface *serverSurface = serverSurfaceCreated.first().first().value<KWaylandServer::SurfaceInterface*>();
|
||||
QVERIFY(serverSurface);
|
||||
|
||||
QSignalSpy damageSpy(serverSurface, SIGNAL(damaged(QRegion)));
|
||||
QSignalSpy damageSpy(serverSurface, &KWaylandServer::SurfaceInterface::damaged);
|
||||
QVERIFY(damageSpy.isValid());
|
||||
|
||||
QSignalSpy frameRenderedSpy(s, SIGNAL(frameRendered()));
|
||||
QSignalSpy frameRenderedSpy(s, &KWayland::Client::Surface::frameRendered);
|
||||
QVERIFY(frameRenderedSpy.isValid());
|
||||
QImage img(QSize(10, 10), QImage::Format_ARGB32_Premultiplied);
|
||||
img.fill(Qt::black);
|
||||
|
@ -362,7 +362,7 @@ void TestWaylandSurface::testFrameCallback()
|
|||
void TestWaylandSurface::testAttachBuffer()
|
||||
{
|
||||
// create the surface
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
KWayland::Client::Surface *s = m_compositor->createSurface();
|
||||
QVERIFY(serverSurfaceCreated.wait());
|
||||
|
@ -395,11 +395,11 @@ void TestWaylandSurface::testAttachBuffer()
|
|||
s->attachBuffer(blackBuffer);
|
||||
s->damage(QRect(0, 0, 24, 24));
|
||||
s->commit(KWayland::Client::Surface::CommitFlag::None);
|
||||
QSignalSpy damageSpy(serverSurface, SIGNAL(damaged(QRegion)));
|
||||
QSignalSpy damageSpy(serverSurface, &KWaylandServer::SurfaceInterface::damaged);
|
||||
QVERIFY(damageSpy.isValid());
|
||||
QSignalSpy mappedSpy(serverSurface, SIGNAL(mapped()));
|
||||
QSignalSpy mappedSpy(serverSurface, &KWaylandServer::SurfaceInterface::mapped);
|
||||
QVERIFY(mappedSpy.isValid());
|
||||
QSignalSpy unmappedSpy(serverSurface, SIGNAL(unmapped()));
|
||||
QSignalSpy unmappedSpy(serverSurface, &KWaylandServer::SurfaceInterface::unmapped);
|
||||
QVERIFY(unmappedSpy.isValid());
|
||||
QVERIFY(damageSpy.wait());
|
||||
QCOMPARE(mappedSpy.count(), 1);
|
||||
|
@ -441,7 +441,7 @@ void TestWaylandSurface::testAttachBuffer()
|
|||
QVERIFY(blueBuffer->isUsed());
|
||||
s->attachBuffer(blueBuffer.data());
|
||||
s->damage(QRect(0, 0, 24, 24));
|
||||
QSignalSpy frameRenderedSpy(s, SIGNAL(frameRendered()));
|
||||
QSignalSpy frameRenderedSpy(s, &KWayland::Client::Surface::frameRendered);
|
||||
QVERIFY(frameRenderedSpy.isValid());
|
||||
s->commit();
|
||||
damageSpy.clear();
|
||||
|
@ -512,7 +512,7 @@ void TestWaylandSurface::testMultipleSurfaces()
|
|||
using namespace KWaylandServer;
|
||||
Registry registry;
|
||||
registry.setEventQueue(m_queue);
|
||||
QSignalSpy shmSpy(®istry, SIGNAL(shmAnnounced(quint32,quint32)));
|
||||
QSignalSpy shmSpy(®istry, &KWayland::Client::Registry::shmAnnounced);
|
||||
registry.create(m_connection->display());
|
||||
QVERIFY(registry.isValid());
|
||||
registry.setup();
|
||||
|
@ -526,7 +526,7 @@ void TestWaylandSurface::testMultipleSurfaces()
|
|||
QVERIFY(pool2.isValid());
|
||||
|
||||
// create the surfaces
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
QScopedPointer<Surface> s1(m_compositor->createSurface());
|
||||
QVERIFY(serverSurfaceCreated.wait());
|
||||
|
@ -551,7 +551,7 @@ void TestWaylandSurface::testMultipleSurfaces()
|
|||
s1->attachBuffer(blackBuffer);
|
||||
s1->damage(QRect(0, 0, 24, 24));
|
||||
s1->commit(Surface::CommitFlag::None);
|
||||
QSignalSpy damageSpy1(serverSurface1, SIGNAL(damaged(QRegion)));
|
||||
QSignalSpy damageSpy1(serverSurface1, &KWaylandServer::SurfaceInterface::damaged);
|
||||
QVERIFY(damageSpy1.isValid());
|
||||
QVERIFY(damageSpy1.wait());
|
||||
|
||||
|
@ -572,7 +572,7 @@ void TestWaylandSurface::testMultipleSurfaces()
|
|||
s2->attachBuffer(redBuffer);
|
||||
s2->damage(QRect(0, 0, 24, 24));
|
||||
s2->commit(Surface::CommitFlag::None);
|
||||
QSignalSpy damageSpy2(serverSurface2, SIGNAL(damaged(QRegion)));
|
||||
QSignalSpy damageSpy2(serverSurface2, &KWaylandServer::SurfaceInterface::damaged);
|
||||
QVERIFY(damageSpy2.isValid());
|
||||
QVERIFY(damageSpy2.wait());
|
||||
|
||||
|
@ -602,13 +602,13 @@ void TestWaylandSurface::testOpaque()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
Surface *s = m_compositor->createSurface();
|
||||
QVERIFY(serverSurfaceCreated.wait());
|
||||
SurfaceInterface *serverSurface = serverSurfaceCreated.first().first().value<KWaylandServer::SurfaceInterface*>();
|
||||
QVERIFY(serverSurface);
|
||||
QSignalSpy opaqueRegionChangedSpy(serverSurface, SIGNAL(opaqueChanged(QRegion)));
|
||||
QSignalSpy opaqueRegionChangedSpy(serverSurface, &KWaylandServer::SurfaceInterface::opaqueChanged);
|
||||
QVERIFY(opaqueRegionChangedSpy.isValid());
|
||||
|
||||
// by default there should be an empty opaque region
|
||||
|
@ -657,13 +657,13 @@ void TestWaylandSurface::testInput()
|
|||
{
|
||||
using namespace KWayland::Client;
|
||||
using namespace KWaylandServer;
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
Surface *s = m_compositor->createSurface();
|
||||
QVERIFY(serverSurfaceCreated.wait());
|
||||
SurfaceInterface *serverSurface = serverSurfaceCreated.first().first().value<KWaylandServer::SurfaceInterface*>();
|
||||
QVERIFY(serverSurface);
|
||||
QSignalSpy inputRegionChangedSpy(serverSurface, SIGNAL(inputChanged(QRegion)));
|
||||
QSignalSpy inputRegionChangedSpy(serverSurface, &KWaylandServer::SurfaceInterface::inputChanged);
|
||||
QVERIFY(inputRegionChangedSpy.isValid());
|
||||
QSignalSpy committedSpy(serverSurface, &SurfaceInterface::committed);
|
||||
QVERIFY(committedSpy.isValid());
|
||||
|
@ -824,7 +824,7 @@ void TestWaylandSurface::testDestroy()
|
|||
connect(m_connection, &ConnectionThread::connectionDied, m_idleInhibitManager, &IdleInhibitManager::destroy);
|
||||
QVERIFY(s->isValid());
|
||||
|
||||
QSignalSpy connectionDiedSpy(m_connection, SIGNAL(connectionDied()));
|
||||
QSignalSpy connectionDiedSpy(m_connection, &KWayland::Client::ConnectionThread::connectionDied);
|
||||
QVERIFY(connectionDiedSpy.isValid());
|
||||
|
||||
delete m_compositorInterface;
|
||||
|
|
|
@ -101,7 +101,7 @@ void TestWindowManagement::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -117,10 +117,10 @@ void TestWindowManagement::init()
|
|||
QVERIFY(m_queue->isValid());
|
||||
|
||||
m_registry = new KWayland::Client::Registry(this);
|
||||
QSignalSpy compositorSpy(m_registry, SIGNAL(compositorAnnounced(quint32,quint32)));
|
||||
QSignalSpy compositorSpy(m_registry, &KWayland::Client::Registry::compositorAnnounced);
|
||||
QVERIFY(compositorSpy.isValid());
|
||||
|
||||
QSignalSpy windowManagementSpy(m_registry, SIGNAL(plasmaWindowManagementAnnounced(quint32,quint32)));
|
||||
QSignalSpy windowManagementSpy(m_registry, &KWayland::Client::Registry::plasmaWindowManagementAnnounced);
|
||||
QVERIFY(windowManagementSpy.isValid());
|
||||
|
||||
|
||||
|
@ -141,7 +141,7 @@ void TestWindowManagement::init()
|
|||
QVERIFY(windowManagementSpy.wait());
|
||||
m_windowManagement = m_registry->createPlasmaWindowManagement(windowManagementSpy.first().first().value<quint32>(), windowManagementSpy.first().last().value<quint32>(), this);
|
||||
|
||||
QSignalSpy windowSpy(m_windowManagement, SIGNAL(windowCreated(KWayland::Client::PlasmaWindow*)));
|
||||
QSignalSpy windowSpy(m_windowManagement, &KWayland::Client::PlasmaWindowManagement::windowCreated);
|
||||
QVERIFY(windowSpy.isValid());
|
||||
m_windowInterface = m_windowManagementInterface->createWindow(this, QUuid::createUuid());
|
||||
m_windowInterface->setPid(1337);
|
||||
|
@ -149,7 +149,7 @@ void TestWindowManagement::init()
|
|||
QVERIFY(windowSpy.wait());
|
||||
m_window = windowSpy.first().first().value<KWayland::Client::PlasmaWindow *>();
|
||||
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
|
||||
m_surface = m_compositor->createSurface(this);
|
||||
|
@ -164,7 +164,7 @@ void TestWindowManagement::testWindowTitle()
|
|||
{
|
||||
m_windowInterface->setTitle(QStringLiteral("Test Title"));
|
||||
|
||||
QSignalSpy titleSpy(m_window, SIGNAL(titleChanged()));
|
||||
QSignalSpy titleSpy(m_window, &KWayland::Client::PlasmaWindow::titleChanged);
|
||||
QVERIFY(titleSpy.isValid());
|
||||
|
||||
QVERIFY(titleSpy.wait());
|
||||
|
@ -176,7 +176,7 @@ void TestWindowManagement::testMinimizedGeometry()
|
|||
{
|
||||
m_window->setMinimizedGeometry(m_surface, QRect(5, 10, 100, 200));
|
||||
|
||||
QSignalSpy geometrySpy(m_windowInterface, SIGNAL(minimizedGeometriesChanged()));
|
||||
QSignalSpy geometrySpy(m_windowInterface, &KWaylandServer::PlasmaWindowInterface::minimizedGeometriesChanged);
|
||||
QVERIFY(geometrySpy.isValid());
|
||||
|
||||
QVERIFY(geometrySpy.wait());
|
||||
|
@ -623,7 +623,7 @@ void TestWindowManagement::testPid()
|
|||
|
||||
//test server not setting a PID for whatever reason
|
||||
QScopedPointer<KWaylandServer::PlasmaWindowInterface> newWindowInterface(m_windowManagementInterface->createWindow(this, QUuid::createUuid()));
|
||||
QSignalSpy windowSpy(m_windowManagement, SIGNAL(windowCreated(KWayland::Client::PlasmaWindow*)));
|
||||
QSignalSpy windowSpy(m_windowManagement, &KWayland::Client::PlasmaWindowManagement::windowCreated);
|
||||
QVERIFY(windowSpy.wait());
|
||||
QScopedPointer<PlasmaWindow> newWindow( windowSpy.first().first().value<KWayland::Client::PlasmaWindow *>());
|
||||
QVERIFY(newWindow);
|
||||
|
|
|
@ -169,7 +169,7 @@ void TestForeign::cleanup()
|
|||
|
||||
void TestForeign::doExport()
|
||||
{
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface.data(), &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
|
||||
m_exportedSurface = m_compositor->createSurface();
|
||||
|
@ -191,7 +191,7 @@ void TestForeign::doExport()
|
|||
m_imported = m_importer->importTopLevel(m_exported->handle());
|
||||
QVERIFY(m_imported->isValid());
|
||||
|
||||
QSignalSpy childSurfaceInterfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy childSurfaceInterfaceCreated(m_compositorInterface.data(), &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
m_childSurface = m_compositor->createSurface();
|
||||
QVERIFY(childSurfaceInterfaceCreated.wait());
|
||||
|
@ -305,7 +305,7 @@ void TestForeign::testExportTwoTimes()
|
|||
QVERIFY(imported2->isValid());
|
||||
|
||||
//create a second child surface
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface.data(), &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
|
||||
KWayland::Client::Surface *childSurface2 = m_compositor->createSurface();
|
||||
|
@ -338,7 +338,7 @@ void TestForeign::testImportTwoTimes()
|
|||
QVERIFY(imported2->isValid());
|
||||
|
||||
//create a second child surface
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface, SIGNAL(surfaceCreated(KWaylandServer::SurfaceInterface*)));
|
||||
QSignalSpy serverSurfaceCreated(m_compositorInterface.data(), &KWaylandServer::CompositorInterface::surfaceCreated);
|
||||
QVERIFY(serverSurfaceCreated.isValid());
|
||||
|
||||
KWayland::Client::Surface *childSurface2 = m_compositor->createSurface();
|
||||
|
|
|
@ -74,7 +74,7 @@ void TestXdgOutput::init()
|
|||
|
||||
// setup connection
|
||||
m_connection = new KWayland::Client::ConnectionThread;
|
||||
QSignalSpy connectedSpy(m_connection, SIGNAL(connected()));
|
||||
QSignalSpy connectedSpy(m_connection, &KWayland::Client::ConnectionThread::connected);
|
||||
m_connection->setSocketName(s_socketName);
|
||||
|
||||
m_thread = new QThread(this);
|
||||
|
@ -118,8 +118,8 @@ void TestXdgOutput::testChanges()
|
|||
using namespace KWaylandServer;
|
||||
using namespace KWayland::Client;
|
||||
KWayland::Client::Registry registry;
|
||||
QSignalSpy announced(®istry, SIGNAL(outputAnnounced(quint32,quint32)));
|
||||
QSignalSpy xdgOutputAnnounced(®istry, SIGNAL(xdgOutputAnnounced(quint32,quint32)));
|
||||
QSignalSpy announced(®istry, &KWayland::Client::Registry::outputAnnounced);
|
||||
QSignalSpy xdgOutputAnnounced(®istry, &KWayland::Client::Registry::xdgOutputAnnounced);
|
||||
|
||||
registry.setEventQueue(m_queue);
|
||||
registry.create(m_connection->display());
|
||||
|
@ -131,7 +131,7 @@ void TestXdgOutput::testChanges()
|
|||
}
|
||||
|
||||
KWayland::Client::Output output;
|
||||
QSignalSpy outputChanged(&output, SIGNAL(changed()));
|
||||
QSignalSpy outputChanged(&output, &KWayland::Client::Output::changed);
|
||||
|
||||
output.setup(registry.bindOutput(announced.first().first().value<quint32>(), announced.first().last().value<quint32>()));
|
||||
QVERIFY(outputChanged.wait());
|
||||
|
@ -139,7 +139,7 @@ void TestXdgOutput::testChanges()
|
|||
QScopedPointer<KWayland::Client::XdgOutputManager> xdgOutputManager(registry.createXdgOutputManager(xdgOutputAnnounced.first().first().value<quint32>(), xdgOutputAnnounced.first().last().value<quint32>(), this));
|
||||
|
||||
QScopedPointer<KWayland::Client::XdgOutput> xdgOutput(xdgOutputManager->getXdgOutput(&output, this));
|
||||
QSignalSpy xdgOutputChanged(xdgOutput.data(), SIGNAL(changed()));
|
||||
QSignalSpy xdgOutputChanged(xdgOutput.data(), &KWayland::Client::XdgOutput::changed);
|
||||
|
||||
//check details are sent on client bind
|
||||
QVERIFY(xdgOutputChanged.wait());
|
||||
|
|
Loading…
Reference in a new issue