AntiMicroX
Loading...
Searching...
No Matches
joystickstatuswindow.h
Go to the documentation of this file.
1/* antimicrox Gamepad to KB+M event mapper
2 * Copyright (C) 2015 Travis Nickles <nickles.travis@gmail.com>
3 * Copyright (C) 2020 Jagoda Górska <juliagoda.pl@protonmail>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation, either version 3 of the License, or
8 * (at your option) any later version.
9
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 */
18
19#ifndef JOYSTICKSTATUSWINDOW_H
20#define JOYSTICKSTATUSWINDOW_H
21
22#include <QDialog>
23
24class InputDevice;
25class QProgressBar;
26class QWidget;
27
28namespace Ui {
30}
31
36class JoystickStatusWindow : public QDialog
37{
39
40 public:
41 explicit JoystickStatusWindow(InputDevice *joystick, QWidget *parent = nullptr);
43
44 InputDevice *getJoystick() const;
45
46 private:
47 void reject();
48 Ui::JoystickStatusWindow *ui;
49
53
54 private slots:
55 void restoreButtonStates(int code);
56 void obliterate();
57 void updateAccelerometerValues(float valueX, float valueY, float valueZ);
58 void updateGyroscopeValues(float valueX, float valueY, float valueZ);
59};
60
61#endif // JOYSTICKSTATUSWINDOW_H
Abstract class representing a hardware input device, e.g a joystick or controller.
Definition inputdevice.h:51
Definition joydpadxml.h:27
The joystick "Properties" window. Shows various raw values to the user.
Definition joystickstatuswindow.h:37
void reject()
Definition joystickstatuswindow.cpp:305
void restoreButtonStates(int code)
Definition joystickstatuswindow.cpp:309
~JoystickStatusWindow()
Definition joystickstatuswindow.cpp:307
void obliterate()
Definition joystickstatuswindow.cpp:322
QProgressBar * m_gyro_axes[3]
Definition joystickstatuswindow.h:52
InputDevice * joystick
Definition joystickstatuswindow.h:50
Ui::JoystickStatusWindow * ui
Definition joystickstatuswindow.h:48
InputDevice * getJoystick() const
Definition joystickstatuswindow.cpp:346
void updateAccelerometerValues(float valueX, float valueY, float valueZ)
Accelerometer "moved" event handler Updates raw accelerometer values on the screen.
Definition joystickstatuswindow.cpp:328
QProgressBar * m_accel_axes[3]
Definition joystickstatuswindow.h:51
void updateGyroscopeValues(float valueX, float valueY, float valueZ)
Gyroscope "moved" event handler Updates raw gyroscope values on the screen.
Definition joystickstatuswindow.cpp:339
Definition aboutdialog.h:26