diff options
author | Adam Tkac <atkac@redhat.com> | 2009-08-28 12:05:24 +0000 |
---|---|---|
committer | Adam Tkac <atkac@redhat.com> | 2009-08-28 12:05:24 +0000 |
commit | d07476360e8ae89572c1164dc7d5c605ad40b963 (patch) | |
tree | 5832310b3ba54cb989fc75bcfcc966fe69a528a8 /unix/xserver/hw/vnc/Input.h | |
parent | 62de8d75d2611924d2ba04406464f31371b93d97 (diff) | |
download | tigervnc-d07476360e8ae89572c1164dc7d5c605ad40b963.tar.gz tigervnc-d07476360e8ae89572c1164dc7d5c605ad40b963.zip |
Move keyboard input related code to Input.h and Input.cc.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3887 3789f03b-4d11-0410-bbf8-ca57d06f2519
Diffstat (limited to 'unix/xserver/hw/vnc/Input.h')
-rw-r--r-- | unix/xserver/hw/vnc/Input.h | 13 |
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 |