From 7a94c109e6805b35150522b6714f04e63d751888 Mon Sep 17 00:00:00 2001 From: Juha Vuolle Date: Thu, 29 Sep 2022 17:53:56 +0300 Subject: Remove disabled sensor gesture code Support for sensor gestures in their then-current form was removed in Qt 6 (QTBUG-95747). This commit removes the disabled code. This is to avoid distraction when keeping the repository up-to-date with rest of Qt. The gestures may be reintroduced in some shape or form in the future (QTBUG-97066). For those reference purposes the old code can be found in the git history. Fixes: QTBUG-107065 Change-Id: If2c50171f84d483dde55600422d138d550124bdc Reviewed-by: Lorn Potter --- .../plugins/test/qtestrecognizer.cpp | 68 ---------------------- 1 file changed, 68 deletions(-) delete mode 100644 tests/auto/qsensorgestures/plugins/test/qtestrecognizer.cpp (limited to 'tests/auto/qsensorgestures/plugins/test/qtestrecognizer.cpp') diff --git a/tests/auto/qsensorgestures/plugins/test/qtestrecognizer.cpp b/tests/auto/qsensorgestures/plugins/test/qtestrecognizer.cpp deleted file mode 100644 index d99cc4bb..00000000 --- a/tests/auto/qsensorgestures/plugins/test/qtestrecognizer.cpp +++ /dev/null @@ -1,68 +0,0 @@ -// Copyright (C) 2016 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 - -#include -#include - -#include "qtestrecognizer.h" -#include "qtestsensorgestureplugin_p.h" - - -QTestRecognizer::QTestRecognizer(QObject *parent) - : QSensorGestureRecognizer(parent), - active(0) -{ - timeout(); -} - -QTestRecognizer::~QTestRecognizer() -{ -} - -void QTestRecognizer::timeout() -{ - Q_EMIT detected("tested"); - Q_EMIT tested(); - QTimer::singleShot(100, this, SLOT(timeout())); -} - - -bool QTestRecognizer::start() -{ - Q_EMIT detected("tested"); - Q_EMIT tested(); - active = true; - return true; -} - -bool QTestRecognizer::stop() -{ - active = false; - return true; -} - -bool QTestRecognizer::isActive() -{ - return active; -} - -void QTestRecognizer::create() -{ - active = false; -} - -QString QTestRecognizer::id() const -{ - return QString("QtSensors.test"); -} - - -int QTestRecognizer::thresholdTime() const -{ - return timerTimeout; -} - -void QTestRecognizer::setThresholdTime(int msec) -{ - timer->setInterval(msec); -} -- cgit v1.2.3