]> git.tdb.fi Git - libs/gltk.git/blob - source/systemkeyboardinput.h
Pass modifier state to key_press and key_release functions
[libs/gltk.git] / source / systemkeyboardinput.h
1 #ifndef MSP_GLTK_SYSTEMKEYBOARDINPUT_H_
2 #define MSP_GLTK_SYSTEMKEYBOARDINPUT_H_
3
4 #include <msp/input/keyboard.h>
5 #include "inputmethod.h"
6
7 namespace Msp {
8 namespace GLtk {
9
10 class SystemKeyboardInput: public InputMethod, public sigc::trackable
11 {
12 private:
13         Input::Keyboard &keyboard;
14         unsigned modifier_state;
15
16 public:
17         SystemKeyboardInput(Root &, Input::Keyboard &);
18
19 private:
20         bool key_press(unsigned);
21         bool key_release(unsigned);
22         bool character(StringCodec::unichar);
23 };
24
25 } // namespace GLtk
26 } // namespace Msp
27
28 #endif