cadMousePro-gui/src/MouseMainWindow.cpp
author František Kučera <franta-hg@frantovo.cz>
Tue, 03 Sep 2019 23:55:00 +0200
branchv_0
changeset 20 cfb5f62ea048
parent 18 7323a89c15e9
child 21 642f32f76c9d
permissions -rw-r--r--
display the USB device name
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
     1
/**
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
     2
 * cadMousePro
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
     3
 * Copyright © 2019 František Kučera (Frantovo.cz, GlobalCode.info)
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
     4
 *
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
     5
 * This program is free software: you can redistribute it and/or modify
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
     6
 * it under the terms of the GNU General Public License as published by
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
     7
 * the Free Software Foundation, either version 3 of the License, or
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
     8
 * (at your option) any later version.
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
     9
 *
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    10
 * This program is distributed in the hope that it will be useful,
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    13
 * GNU General Public License for more details.
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    14
 *
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    16
 * along with this program. If not, see <http://www.gnu.org/licenses/>.
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    17
 */
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    18
#include <QLabel>
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    19
#include <QPushButton>
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    20
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    21
#include "MouseMainWindow.h"
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    22
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    23
MouseMainWindow::MouseMainWindow() {
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    24
	proxy = new InfoGlobalcodeMouseCadMouseProInterface("info.globalcode.mouse.cadMousePro", "/info/globalcode/mouse/cadMousePro", connection, this);
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    25
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    26
	setWindowTitle("cadMousePro");
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    27
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    28
	initStatusPanel();
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    29
	initConfigurationPanel();
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    30
	initAboutPanel();
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    31
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    32
	setCentralWidget(tabs);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    33
	refresh();
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    34
}
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    35
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    36
void MouseMainWindow::initStatusPanel() {
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    37
	QWidget* panel = new QWidget(this);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    38
	QFormLayout* layout = new QFormLayout(panel);
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    39
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    40
	int f = 0;
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    41
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    42
	statusProxy->setEnabled(false);
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    43
	statusUPower->setEnabled(false);
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    44
	statusDevice->setEnabled(false);
20
cfb5f62ea048 display the USB device name
František Kučera <franta-hg@frantovo.cz>
parents: 18
diff changeset
    45
	statusName->setToolTip("name of the USB device – usually the wireless adaptor");
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    46
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    47
	layout->setWidget(f++, QFormLayout::FieldRole, statusProxy);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    48
	layout->setWidget(f++, QFormLayout::FieldRole, statusUPower);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    49
	layout->setWidget(f++, QFormLayout::FieldRole, statusDevice);
20
cfb5f62ea048 display the USB device name
František Kučera <franta-hg@frantovo.cz>
parents: 18
diff changeset
    50
	layout->setWidget(f++, QFormLayout::FieldRole, statusName);
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    51
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    52
	QPushButton* refreshButton = new QPushButton("Refresh", panel);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    53
	layout->setWidget(f++, QFormLayout::FieldRole, refreshButton);
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    54
	connect(refreshButton, &QPushButton::clicked, this, &MouseMainWindow::refresh);
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    55
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    56
	tabs->addTab(panel, "Status");
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    57
}
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    58
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    59
void MouseMainWindow::initConfigurationPanel() {
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    60
	QWidget* panel = new QWidget(this);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    61
	QFormLayout* layout = new QFormLayout(panel);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    62
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    63
	int f = 0;
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    64
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    65
	configureLiftOffDetection->setChecked(true);
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    66
	layout->setWidget(f++, QFormLayout::FieldRole, configureLiftOffDetection);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    67
	layout->setWidget(f++, QFormLayout::FieldRole, configureSmartScrolling);
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    68
	configureFrequency250->setChecked(true);
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    69
	layout->setWidget(f++, QFormLayout::FieldRole, configureFrequency125);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    70
	layout->setWidget(f++, QFormLayout::FieldRole, configureFrequency250);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    71
	layout->setWidget(f++, QFormLayout::FieldRole, configureFrequency500);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    72
	layout->setWidget(f++, QFormLayout::FieldRole, configureFrequency1000);
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    73
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    74
	QPushButton* configureButton = new QPushButton("Configure", panel);
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    75
	configureButton->setToolTip("n.b. current interface is write-only and the controls above just configures the mouse – does not show current configuration");
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    76
	layout->setWidget(f++, QFormLayout::FieldRole, configureButton);
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    77
	connect(configureButton, &QPushButton::clicked, this, &MouseMainWindow::configure);
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    78
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    79
	message->setReadOnly(true);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    80
	layout->setWidget(f++, QFormLayout::FieldRole, new QLabel("Result:", panel));
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    81
	layout->setWidget(f++, QFormLayout::FieldRole, message);
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    82
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    83
	tabs->addTab(panel, "Configuration");
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    84
}
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
    85
18
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    86
void MouseMainWindow::appendAboutLine(QFormLayout* layout, const QString& label, const QString& value, QWidget* parent) {
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    87
	QLabel* labelWidget = new QLabel(label, parent);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    88
	QLabel* textWidget = new QLabel(value, parent);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    89
	
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    90
	textWidget->setTextInteractionFlags(Qt::TextInteractionFlag::TextSelectableByMouse | Qt::TextInteractionFlag::TextBrowserInteraction);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    91
	textWidget->setOpenExternalLinks(true);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    92
	
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    93
	layout->addRow(labelWidget, textWidget);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    94
}
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    95
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    96
void MouseMainWindow::initAboutPanel() {
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    97
	QWidget* panel = new QWidget(this);
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
    98
	QFormLayout* layout = new QFormLayout(panel);
18
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
    99
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
   100
	appendAboutLine(layout, "Program name:", "cadMousePro", panel);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
   101
	appendAboutLine(layout, "Description:", "configuration tool for 3DConnexion CadMouse Pro Wireless", panel);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
   102
	appendAboutLine(layout, "Author:", "Ing. František Kučera (Frantovo.cz, GlobalCode.info)", panel);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
   103
	appendAboutLine(layout, "License:", "<a href='https://www.gnu.org/licenses/gpl-3.0.html'>GNU GPLv3+</a>", panel);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
   104
	appendAboutLine(layout, "Contact and support:", "<a href='https://mouse.globalcode.info/'>https://mouse.globalcode.info/</a>", panel);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
   105
	appendAboutLine(layout, "BTC:", "bc1qmt3qgzcf3a0f0tvnm70zjr0vhlchfyrjtnleqm", panel);
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
   106
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
   107
	tabs->addTab(panel, "About");
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   108
}
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   109
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   110
void MouseMainWindow::refresh() {
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   111
	statusProxy->setChecked(proxy->isValid());
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   112
	statusDevice->setChecked(proxy->devicePresent());
20
cfb5f62ea048 display the USB device name
František Kučera <franta-hg@frantovo.cz>
parents: 18
diff changeset
   113
	statusName->setText(proxy->deviceName());
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   114
}
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   115
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   116
void MouseMainWindow::configure() {
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
   117
	message->setText("…");
18
7323a89c15e9 clickable links in About panel
František Kučera <franta-hg@frantovo.cz>
parents: 17
diff changeset
   118
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   119
	int frequency; // TODO: get value from the group
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   120
	if (configureFrequency125->isChecked()) frequency = 125;
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   121
	else if (configureFrequency250->isChecked()) frequency = 250;
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   122
	else if (configureFrequency500->isChecked()) frequency = 500;
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   123
	else if (configureFrequency1000->isChecked()) frequency = 1000;
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   124
	else frequency = 250;
17
d37c6dd9aa20 tabs: Status, Configuration, About
František Kučera <franta-hg@frantovo.cz>
parents: 16
diff changeset
   125
16
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   126
	auto response = proxy->configure(configureLiftOffDetection->isChecked(), configureSmartScrolling->isChecked(), frequency);
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   127
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   128
	response.waitForFinished();
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   129
	if (response.isError()) message->setText("Error: " + response.error().message());
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   130
	else message->setText("mouse configured");
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   131
2705911938b4 GUI for mouse configuration over D-Bus daemon
František Kučera <franta-hg@frantovo.cz>
parents:
diff changeset
   132
}