diff options
| author | Sebastien Braun | 2010-11-04 00:38:24 +0100 |
|---|---|---|
| committer | Sebastien Braun | 2010-11-04 00:38:24 +0100 |
| commit | 4fcc0efae9738bb28922da592fff78cfef50277b (patch) | |
| tree | b3855b36abe874606a802ec75fc573543d2d7b35 /src/input/x11FakeKeyboardHandler.h | |
| parent | [PVSMGRTOUCH] resetall bug fixed (diff) | |
| parent | Documentation fixes and code cleanup (diff) | |
| download | pvs-4fcc0efae9738bb28922da592fff78cfef50277b.tar.gz pvs-4fcc0efae9738bb28922da592fff78cfef50277b.tar.xz pvs-4fcc0efae9738bb28922da592fff78cfef50277b.zip | |
Merge input handling work to master
Diffstat (limited to 'src/input/x11FakeKeyboardHandler.h')
| -rw-r--r-- | src/input/x11FakeKeyboardHandler.h | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/src/input/x11FakeKeyboardHandler.h b/src/input/x11FakeKeyboardHandler.h index 3dde7cc..7f2d12e 100644 --- a/src/input/x11FakeKeyboardHandler.h +++ b/src/input/x11FakeKeyboardHandler.h @@ -19,10 +19,21 @@ #include "inputEventHandler.h" -class X11FakeKeyboardHandler : public DefaultInputEventHandler<InputEvent::ET_KEY> +/** + * Send keyboard events via the XTest extension. + * This is unbelievably brittle in the face of non-system-standard keyboard + * mappings. Every Linux distribution seems to set up XTest handling in + * a different way. The code goes out of its way to find a usable mapping + * and use it. + */ +class X11FakeKeyboardHandler : public InputEventHandler< + input_policy::Match<InputEvent::ET_KEY, InputEvent::EC_PRESS>, + input_policy::Match<InputEvent::ET_KEY, InputEvent::EC_RELEASE>, + input_policy::Require<input_policy::X11GUI>, + input_policy::Unprivileged> { public: - void handle(InputEvent const&, InputEventContext const* = 0); + void doHandle(InputEvent const&, InputEventContext const* = 0); void initialize(); }; |
