summaryrefslogtreecommitdiffstats
path: root/unix/xserver/hw/vnc/Input.h
diff options
context:
space:
mode:
Diffstat (limited to 'unix/xserver/hw/vnc/Input.h')
-rw-r--r--unix/xserver/hw/vnc/Input.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/unix/xserver/hw/vnc/Input.h b/unix/xserver/hw/vnc/Input.h
index 49cedf29..1bfec922 100644
--- a/unix/xserver/hw/vnc/Input.h
+++ b/unix/xserver/hw/vnc/Input.h
@@ -58,4 +58,17 @@ private:
rfb::Point cursorPos, oldCursorPos;
};
+/* Represents keyboard device. */
+class KeyboardDevice {
+public:
+ /* Create new Keyboard device instance. */
+ KeyboardDevice(void);
+
+ void Press(rdr::U32 keysym) { keyEvent(keysym, true); }
+ void Release(rdr::U32 keysym) { keyEvent(keysym, false); }
+private:
+ void keyEvent(rdr::U32 keysym, bool down);
+ DeviceIntPtr dev;
+};
+
#endif