From e18e2eb57c3cd7ba725a4096581cdb6598e005f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Thu, 11 Aug 2016 15:18:40 +0200 Subject: [PATCH] [libinput] Rename Device::tapEnabledByDefault to tapToClickEnabledByDefault Slightly more descriptive name what the feature is about. --- autotests/libinput/device_test.cpp | 4 ++-- libinput/device.cpp | 2 +- libinput/device.h | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/autotests/libinput/device_test.cpp b/autotests/libinput/device_test.cpp index 1952dd79ad..af2eb97f16 100644 --- a/autotests/libinput/device_test.cpp +++ b/autotests/libinput/device_test.cpp @@ -278,8 +278,8 @@ void TestLibinputDevice::testTapEnabledByDefault() device.tapEnabledByDefault = enabled; Device d(&device); - QCOMPARE(d.tapEnabledByDefault(), enabled); - QCOMPARE(d.property("tapEnabledByDefault").toBool(), enabled); + QCOMPARE(d.tapToClickEnabledByDefault(), enabled); + QCOMPARE(d.property("tapToClickEnabledByDefault").toBool(), enabled); } void TestLibinputDevice::testSupportsDisableWhileTyping_data() diff --git a/libinput/device.cpp b/libinput/device.cpp index de937384e1..867a9696c6 100644 --- a/libinput/device.cpp +++ b/libinput/device.cpp @@ -89,7 +89,7 @@ Device::Device(libinput_device *device, QObject *parent) , m_product(libinput_device_get_id_product(m_device)) , m_vendor(libinput_device_get_id_vendor(m_device)) , m_tapFingerCount(libinput_device_config_tap_get_finger_count(m_device)) - , m_tapEnabledByDefault(libinput_device_config_tap_get_default_enabled(m_device) == LIBINPUT_CONFIG_TAP_ENABLED) + , m_tapToClickEnabledByDefault(libinput_device_config_tap_get_default_enabled(m_device) == LIBINPUT_CONFIG_TAP_ENABLED) , m_tapToClick(libinput_device_config_tap_get_enabled(m_device)) , m_supportsDisableWhileTyping(libinput_device_config_dwt_is_available(m_device)) , m_supportsPointerAcceleration(libinput_device_config_accel_is_available(m_device)) diff --git a/libinput/device.h b/libinput/device.h index 893d6d306e..872bc618f2 100644 --- a/libinput/device.h +++ b/libinput/device.h @@ -49,7 +49,7 @@ class Device : public QObject Q_PROPERTY(quint32 vendor READ vendor CONSTANT) Q_PROPERTY(Qt::MouseButtons supportedButtons READ supportedButtons CONSTANT) Q_PROPERTY(int tapFingerCount READ tapFingerCount CONSTANT) - Q_PROPERTY(bool tapEnabledByDefault READ tapEnabledByDefault CONSTANT) + Q_PROPERTY(bool tapToClickEnabledByDefault READ tapToClickEnabledByDefault CONSTANT) Q_PROPERTY(bool supportsDisableWhileTyping READ supportsDisableWhileTyping CONSTANT) Q_PROPERTY(bool supportsPointerAcceleration READ supportsPointerAcceleration CONSTANT) Q_PROPERTY(bool supportsLeftHanded READ supportsLeftHanded CONSTANT) @@ -109,8 +109,8 @@ public: int tapFingerCount() const { return m_tapFingerCount; } - bool tapEnabledByDefault() const { - return m_tapEnabledByDefault; + bool tapToClickEnabledByDefault() const { + return m_tapToClickEnabledByDefault; } bool isTapToClick() const { return m_tapToClick; @@ -198,7 +198,7 @@ private: quint32 m_vendor; Qt::MouseButtons m_supportedButtons = Qt::NoButton; int m_tapFingerCount; - bool m_tapEnabledByDefault; + bool m_tapToClickEnabledByDefault; bool m_tapToClick; bool m_supportsDisableWhileTyping; bool m_supportsPointerAcceleration;