|
KiCad PCB EDA Suite
|
#include <libspnav_driver.h>
Public Member Functions | |
| LIBSPNAV_DRIVER () | |
| ~LIBSPNAV_DRIVER () | |
| bool | Connect () override |
| Connect to the device. | |
| void | Disconnect () override |
| Disconnect from the device. | |
| void | Poll () override |
| Poll for pending events and dispatch them to the handler. | |
| void | SetHandler (SPACEMOUSE_HANDLER *aHandler) |
Protected Attributes | |
| SPACEMOUSE_HANDLER * | m_handler = nullptr |
Private Attributes | |
| bool | m_client_connected = false |
Static Private Attributes | |
| static std::mutex | s_mutex |
| static int | s_connection_count = 0 |
| static bool | s_spnav_connected = false |
Definition at line 36 of file libspnav_driver.h.
| LIBSPNAV_DRIVER::LIBSPNAV_DRIVER | ( | ) |
Definition at line 34 of file libspnav_driver.cpp.
| LIBSPNAV_DRIVER::~LIBSPNAV_DRIVER | ( | ) |
Definition at line 38 of file libspnav_driver.cpp.
References Disconnect().
|
overridevirtual |
Connect to the device.
Returns true on success.
Implements SPACENAV_DRIVER.
Definition at line 43 of file libspnav_driver.cpp.
References m_client_connected, s_connection_count, s_mutex, and s_spnav_connected.
|
overridevirtual |
Disconnect from the device.
Implements SPACENAV_DRIVER.
Definition at line 64 of file libspnav_driver.cpp.
References m_client_connected, s_connection_count, s_mutex, and s_spnav_connected.
Referenced by ~LIBSPNAV_DRIVER().
|
overridevirtual |
Poll for pending events and dispatch them to the handler.
Implements SPACENAV_DRIVER.
Definition at line 82 of file libspnav_driver.cpp.
References m_client_connected, SPACENAV_DRIVER::m_handler, s_mutex, and s_spnav_connected.
|
inlineinherited |
Definition at line 54 of file spacenav_driver.h.
References m_handler.
|
private |
Definition at line 52 of file libspnav_driver.h.
Referenced by Connect(), Disconnect(), and Poll().
|
protectedinherited |
Definition at line 57 of file spacenav_driver.h.
Referenced by LIBSPNAV_DRIVER::Poll(), and SetHandler().
|
staticprivate |
Definition at line 49 of file libspnav_driver.h.
Referenced by Connect(), and Disconnect().
|
staticprivate |
Definition at line 48 of file libspnav_driver.h.
Referenced by Connect(), Disconnect(), and Poll().
|
staticprivate |
Definition at line 50 of file libspnav_driver.h.
Referenced by Connect(), Disconnect(), and Poll().