Last change
on this file was
12928,
checked in by westram, 10 years ago
|
- clone AW_IS_IMAGEREF from gtk (and replace hardcoded tests)
|
-
Property svn:eol-style set to
native
-
Property svn:keywords set to
Author Date Id Revision
|
File size:
1.9 KB
|
Line | |
---|
1 | // =========================================================== // |
---|
2 | // // |
---|
3 | // File : aw_keysym.hxx // |
---|
4 | // Purpose : // |
---|
5 | // // |
---|
6 | // Institute of Microbiology (Technical University Munich) // |
---|
7 | // http://www.arb-home.de/ // |
---|
8 | // // |
---|
9 | // =========================================================== // |
---|
10 | |
---|
11 | #ifndef AW_KEYSYM_HXX |
---|
12 | #define AW_KEYSYM_HXX |
---|
13 | |
---|
14 | inline bool AW_IS_IMAGEREF(const char* label) { // @@@ move into AW_window.cxx aftermerge |
---|
15 | //! return true if 'label' is an image reference |
---|
16 | return label[0] == '#'; |
---|
17 | } |
---|
18 | |
---|
19 | enum AW_key_code { |
---|
20 | AW_KEY_NONE, |
---|
21 | AW_KEY_ESCAPE, |
---|
22 | AW_KEY_F1, |
---|
23 | AW_KEY_F2, |
---|
24 | AW_KEY_F3, |
---|
25 | AW_KEY_F4, |
---|
26 | AW_KEY_F5, |
---|
27 | AW_KEY_F6, |
---|
28 | AW_KEY_F7, |
---|
29 | AW_KEY_F8, |
---|
30 | AW_KEY_F9, |
---|
31 | AW_KEY_F10, |
---|
32 | AW_KEY_F11, |
---|
33 | AW_KEY_F12, |
---|
34 | AW_KEY_LEFT, |
---|
35 | AW_KEY_RIGHT, |
---|
36 | AW_KEY_UP, |
---|
37 | AW_KEY_DOWN, |
---|
38 | AW_KEY_DELETE, |
---|
39 | AW_KEY_BACKSPACE, |
---|
40 | AW_KEY_INSERT, |
---|
41 | AW_KEY_HELP, |
---|
42 | AW_KEY_HOME, |
---|
43 | AW_KEY_END, |
---|
44 | AW_KEY_RETURN, |
---|
45 | AW_KEY_TAB, |
---|
46 | AW_KEY_ASCII |
---|
47 | }; |
---|
48 | |
---|
49 | enum AW_key_mod { |
---|
50 | AW_KEYMODE_NONE = 0, |
---|
51 | AW_KEYMODE_SHIFT = 2, |
---|
52 | AW_KEYMODE_CONTROL = 4, |
---|
53 | AW_KEYMODE_ALT = 8, // Alt or Meta key |
---|
54 | AW_KEYMODE_NUMLOCK = 16, |
---|
55 | }; |
---|
56 | |
---|
57 | // define some inline functions to avoid comparing apples and oranges: |
---|
58 | inline bool operator==(AW_key_code, char); |
---|
59 | inline bool operator!=(AW_key_code, char); |
---|
60 | inline bool operator==(char, AW_key_code); |
---|
61 | inline bool operator!=(char, AW_key_code); |
---|
62 | |
---|
63 | inline bool operator==(AW_key_mod, char); |
---|
64 | inline bool operator!=(AW_key_mod, char); |
---|
65 | inline bool operator==(char, AW_key_mod); |
---|
66 | inline bool operator!=(char, AW_key_mod); |
---|
67 | |
---|
68 | #else |
---|
69 | #error aw_keysym.hxx included twice |
---|
70 | #endif // AW_KEYSYM_HXX |
---|
Note: See
TracBrowser
for help on using the repository browser.