AntiMicroX
Loading...
Searching...
No Matches
joysensoriothreadhelper.h
Go to the documentation of this file.
1/* antimicrox Gamepad to KB+M event mapper
2 * Copyright (C) 2022 Max Maisel <max.maisel@posteo.de>
3 *
4 * This program is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation, either version 3 of the License, or
7 * (at your option) any later version.
8
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17#pragma once
18
19#include "joysensordirection.h"
20
21#include <QHash>
22#include <QObject>
23
24class JoyButtonSlot;
25class JoySensor;
26
Represents action which can be performed after pressing button.
Definition joybuttonslot.h:38
Definition joydpadxml.h:27
Some helper methods which run in the IO thread and are called from the GUI thread.
Definition joysensoriothreadhelper.h:32
QHash< JoySensorDirection, JoyButtonSlot * > m_pending_slots
Definition joysensoriothreadhelper.h:46
void setFromPendingSlots()
Applies pending slot values to the buttons Should be called via QMetaObject::invokeMethod.
Definition joysensoriothreadhelper.cpp:59
void clearPendingSlots()
Clears pending slot values.
Definition joysensoriothreadhelper.cpp:53
void clearButtonsSlotsEventReset()
Calls JoyButton::clearSlotEventReset on all JoyButtons of the underlying sensor. Should be called via...
Definition joysensoriothreadhelper.cpp:85
void setPendingSlots(QHash< JoySensorDirection, JoyButtonSlot * > *tempSlots)
Sets pending slot values The values are applied to the buttons by calling setFromPendingSlots.
Definition joysensoriothreadhelper.cpp:39
JoySensor * m_sensor
Definition joysensoriothreadhelper.h:45
Represents one sensor in a SetJoystick and its connections to other parts of the application....
Definition joysensor.h:40