|
QGroundControl
Ground Control Station for MAVLink Drones
|
#include <JoystickManager.h>
Inheritance diagram for JoystickManager:
Collaboration diagram for JoystickManager:Public Slots | |
| void | init () |
Signals | |
| void | activeJoystickChanged (Joystick *joystick) |
| void | activeJoystickEnabledForActiveVehicleChanged () |
| void | availableJoystickNamesChanged () |
Public Member Functions | |
| JoystickManager (QObject *parent=nullptr) | |
| Number of connected joysticks. | |
| ~JoystickManager () override | |
| QStringList | availableJoystickNames () const |
| int | joystickCount () const |
| Joystick * | activeJoystick () |
| bool | activeJoystickEnabledForActiveVehicle () const |
| void | setActiveJoystickEnabledForActiveVehicle (bool enabled) |
| Q_INVOKABLE QStringList | linkedGroupMembers (const QString &groupId) const |
| Q_INVOKABLE Joystick * | joystickByName (const QString &name) const |
| Get joystick by name (returns nullptr if not found) | |
Static Public Member Functions | |
| static JoystickManager * | instance () |
Definition at line 12 of file JoystickManager.h.
|
explicit |
Number of connected joysticks.
List of available joystick names Note: The active joystick name may be not in this list if the joystick is not currently connected
Definition at line 25 of file JoystickManager.cc.
References MultiVehicleManager::activeVehicleChanged(), AndroidEvents::instance(), MultiVehicleManager::instance(), SDLJoystick::pumpEvents(), Fact::rawValueChanged(), and AndroidEvents::resumed().
|
override |
Definition at line 64 of file JoystickManager.cc.
References JoystickSDL::shutdown().
| Joystick * JoystickManager::activeJoystick | ( | ) |
Definition at line 166 of file JoystickManager.cc.
Referenced by JoystickComponent::setupComplete().
|
signal |
Referenced by QGCCameraManager::_vehicleReady(), and JoystickComponent::JoystickComponent().
| bool JoystickManager::activeJoystickEnabledForActiveVehicle | ( | ) | const |
Definition at line 171 of file JoystickManager.cc.
References MultiVehicleManager::activeVehicle(), and MultiVehicleManager::instance().
Referenced by Vehicle::virtualTabletJoystickValue().
|
signal |
|
inline |
Definition at line 39 of file JoystickManager.h.
|
signal |
|
slot |
Definition at line 86 of file JoystickManager.cc.
References JoystickSDL::init().
|
static |
Definition at line 81 of file JoystickManager.cc.
Referenced by QGCCameraManager::_vehicleReady(), QGCCorePlugin::createQmlApplicationEngine(), JoystickComponent::JoystickComponent(), sdlEventWatcher(), JoystickComponent::setupComplete(), and Vehicle::virtualTabletJoystickValue().
| Joystick * JoystickManager::joystickByName | ( | const QString & | name | ) | const |
Get joystick by name (returns nullptr if not found)
Definition at line 364 of file JoystickManager.cc.
|
inline |
Definition at line 40 of file JoystickManager.h.
| QStringList JoystickManager::linkedGroupMembers | ( | const QString & | groupId | ) | const |
Get all joysticks in a linked group Returns empty list if groupId is empty or no matches found
Definition at line 349 of file JoystickManager.cc.
| void JoystickManager::setActiveJoystickEnabledForActiveVehicle | ( | bool | enabled | ) |
Definition at line 180 of file JoystickManager.cc.
References MultiVehicleManager::activeVehicle(), and MultiVehicleManager::instance().