NifTK
16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
|
Public Types | |
enum | Hotkey { CTRL_ALT_F5 = 0x00030074, CTRL_ALT_F6 = 0x00030075, CTRL_ALT_F7 = 0x00030076 } |
Signals | |
void | HotkeyPressed (niftk::WindowsHotkeyHandler *, int) |
Public Member Functions | |
WindowsHotkeyHandler (Hotkey hk) | |
virtual | ~WindowsHotkeyHandler () |
Protected Member Functions | |
virtual void | run () |
Custom thread with low-level Windows event loop to handle hotkey messages. These are not processed by Qt and simply disappear in its event handling mechanism. Works only on Windows. Instances of this object should be created by the main event loop. Do not moveToThread() this object to itself!
niftk::WindowsHotkeyHandler::WindowsHotkeyHandler | ( | Hotkey | hk | ) |
Creates a new handler and starts the corresponding thread. Note that you have to know in advance which hotkey you want, there is no way to change it afterwards.
Init happens in run(), not in this constructor. Unfortunately, this means that error reporting is practically non-existent.
nothing | should not throw anything. |
|
virtual |
|
signal |
Beware: you really should connect this as QueuedConnection!
|
protectedvirtual |
Does the initialisation and runs a low-level Windows message loop. This will not do any Qt signal delivery! So it's important that you do not moveToThread() this object.