Rabbit Remote Control 0.1.0-bate5
Loading...
Searching...
No Matches
Public Member Functions | Private Member Functions | Private Attributes | List of all members
KeyInjector Class Reference
Inheritance diagram for KeyInjector:
Inheritance graph
[legend]
Collaboration diagram for KeyInjector:
Collaboration graph
[legend]

Public Member Functions

 KeyInjector (QObject *parent=nullptr)
 
bool init ()
 
bool sendKey (Qt::Key key)
 
bool sendKeyCombo (const QList< Qt::Key > &modifiers, Qt::Key key)
 
bool sendSuper ()
 
void cleanup ()
 

Private Member Functions

bool initX11 ()
 
bool initUInput ()
 
void cleanupX11 ()
 
void cleanupUInput ()
 
bool sendKeyX11 (Qt::Key key, bool press)
 
bool sendKeyUInput (int linux_keycode, int value)
 
int qtKeyToKeySym (Qt::Key key, bool *ok=nullptr)
 
int qtKeyToLinuxKey (Qt::Key key, bool *ok=nullptr)
 

Private Attributes

bool useX11 = false
 
bool useUinput = false
 
void * x11Display = nullptr
 
int uinputFd = -1
 

Detailed Description

Definition at line 10 of file KeyInjector.h.

Constructor & Destructor Documentation

◆ KeyInjector()

KeyInjector::KeyInjector ( QObject *  parent = nullptr)
explicit

Definition at line 24 of file KeyInjector.cpp.

◆ ~KeyInjector()

KeyInjector::~KeyInjector ( )

Definition at line 29 of file KeyInjector.cpp.

Member Function Documentation

◆ cleanup()

void KeyInjector::cleanup ( )

Definition at line 176 of file KeyInjector.cpp.

◆ cleanupUInput()

void KeyInjector::cleanupUInput ( )
private

Definition at line 165 of file KeyInjector.cpp.

◆ cleanupX11()

void KeyInjector::cleanupX11 ( )
private

Definition at line 102 of file KeyInjector.cpp.

◆ init()

bool KeyInjector::init ( )

Definition at line 34 of file KeyInjector.cpp.

◆ initUInput()

bool KeyInjector::initUInput ( )
private

Definition at line 112 of file KeyInjector.cpp.

◆ initX11()

bool KeyInjector::initX11 ( )
private

Definition at line 70 of file KeyInjector.cpp.

◆ qtKeyToKeySym()

int KeyInjector::qtKeyToKeySym ( Qt::Key  key,
bool *  ok = nullptr 
)
private

Definition at line 293 of file KeyInjector.cpp.

◆ qtKeyToLinuxKey()

int KeyInjector::qtKeyToLinuxKey ( Qt::Key  key,
bool *  ok = nullptr 
)
private

Definition at line 333 of file KeyInjector.cpp.

◆ sendKey()

bool KeyInjector::sendKey ( Qt::Key  key)

Definition at line 184 of file KeyInjector.cpp.

◆ sendKeyCombo()

bool KeyInjector::sendKeyCombo ( const QList< Qt::Key > &  modifiers,
Qt::Key  key 
)

Definition at line 189 of file KeyInjector.cpp.

◆ sendKeyUInput()

bool KeyInjector::sendKeyUInput ( int  linux_keycode,
int  value 
)
private

Definition at line 262 of file KeyInjector.cpp.

◆ sendKeyX11()

bool KeyInjector::sendKeyX11 ( Qt::Key  key,
bool  press 
)
private

Definition at line 236 of file KeyInjector.cpp.

◆ sendSuper()

bool KeyInjector::sendSuper ( )

Definition at line 231 of file KeyInjector.cpp.

Member Data Documentation

◆ uinputFd

int KeyInjector::uinputFd = -1
private

Definition at line 50 of file KeyInjector.h.

◆ useUinput

bool KeyInjector::useUinput = false
private

Definition at line 48 of file KeyInjector.h.

◆ useX11

bool KeyInjector::useX11 = false
private

Definition at line 47 of file KeyInjector.h.

◆ x11Display

void* KeyInjector::x11Display = nullptr
private

Definition at line 49 of file KeyInjector.h.


The documentation for this class was generated from the following files: