From 6abbecf9422af043d51cbb8b3d8c2c188ee40fd3 Mon Sep 17 00:00:00 2001 From: Johan Klokkhammer Helsing Date: Thu, 10 Oct 2019 12:45:25 +0200 Subject: evdevtouch: Fix touch device count not being updated When this was refactored in 3bc10fb9bb9 to use unique pointers, a move was added before the connection, so it would essentially always try to connect a nullptr. Change-Id: Iab7fce88bc73afd78e6b63ffaef7358f3f4ce7e3 Reviewed-by: Rainer Keller --- src/platformsupport/input/evdevtouch/qevdevtouchmanager.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/platformsupport') diff --git a/src/platformsupport/input/evdevtouch/qevdevtouchmanager.cpp b/src/platformsupport/input/evdevtouch/qevdevtouchmanager.cpp index b280f27fac..bf2df93d11 100644 --- a/src/platformsupport/input/evdevtouch/qevdevtouchmanager.cpp +++ b/src/platformsupport/input/evdevtouch/qevdevtouchmanager.cpp @@ -98,8 +98,8 @@ void QEvdevTouchManager::addDevice(const QString &deviceNode) qCDebug(qLcEvdevTouch, "evdevtouch: Adding device at %ls", qUtf16Printable(deviceNode)); auto handler = qt_make_unique(deviceNode, m_spec); if (handler) { - m_activeDevices.add(deviceNode, std::move(handler)); connect(handler.get(), &QEvdevTouchScreenHandlerThread::touchDeviceRegistered, this, &QEvdevTouchManager::updateInputDeviceCount); + m_activeDevices.add(deviceNode, std::move(handler)); } else { qWarning("evdevtouch: Failed to open touch device %ls", qUtf16Printable(deviceNode)); } -- cgit v1.2.3