# HG changeset patch # User František Kučera # Date 1591714031 -7200 # Node ID 3cbac1956f05dcc891e8820f96b65256f12fcd47 # Parent 148bda718c935acd431697050540346a3f18ee74 log values while configuring mouse, checking mouse presence or reading mouse name diff -r 148bda718c93 -r 3cbac1956f05 cadMousePro-daemon/src/Daemon.h --- a/cadMousePro-daemon/src/Daemon.h Tue Jun 09 16:29:12 2020 +0200 +++ b/cadMousePro-daemon/src/Daemon.h Tue Jun 09 16:47:11 2020 +0200 @@ -47,11 +47,13 @@ Q_PROPERTY(bool devicePresent READ devicePresent) bool devicePresent() { - std::wcout << L"checking mouse presence" << std::endl; + std::wcout << L"checking mouse presence: "; try { getMouse(); + std::wcout << L"present" << std::endl; return true; } catch (const HIDException& e) { + std::wcout << std::endl; logException(e); return false; } @@ -59,17 +61,26 @@ Q_PROPERTY(QString deviceName READ deviceName) QString deviceName() { - std::wcout << L"reading mouse name" << std::endl; + std::wcout << L"reading mouse name: "; try { - return QString::fromStdWString(getMouse().getProductName()); + auto productName = getMouse().getProductName(); + std::wcout << productName << std::endl; + return QString::fromStdWString(productName); } catch (HIDException& e) { + std::wcout << std::endl; logException(e); return QString(); } } void configure(bool liftOffDetection, bool smartScrolling, bool remapWheelPress, bool remapGestureButton, int frequency) { - std::wcout << L"configuring mouse" << std::endl; + std::wcout << L"configuring mouse:" + << L" liftOffDetection=" << liftOffDetection + << L" smartScrolling=" << smartScrolling + << L" remapWheelPress=" << remapWheelPress + << L" remapGestureButton=" << remapGestureButton + << L" frequency=" << frequency + << std::endl; try { CadMouseConfig config; config.setLiftOffDetection(liftOffDetection);