aboutsummaryrefslogtreecommitdiff
path: root/src/Keys.hh
diff options
context:
space:
mode:
Diffstat (limited to 'src/Keys.hh')
-rw-r--r--src/Keys.hh17
1 files changed, 14 insertions, 3 deletions
diff --git a/src/Keys.hh b/src/Keys.hh
index c0a6d6c..57e826c 100644
--- a/src/Keys.hh
+++ b/src/Keys.hh
@@ -19,7 +19,7 @@
19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20// DEALINGS IN THE SOFTWARE. 20// DEALINGS IN THE SOFTWARE.
21 21
22// $Id: Keys.hh,v 1.21 2003/04/14 12:10:14 fluxgen Exp $ 22// $Id: Keys.hh,v 1.22 2003/04/15 00:50:24 rathnor Exp $
23 23
24#ifndef KEYS_HH 24#ifndef KEYS_HH
25#define KEYS_HH 25#define KEYS_HH
@@ -74,6 +74,18 @@ public:
74 explicit Keys(const char *filename=0); 74 explicit Keys(const char *filename=0);
75 /// destructor 75 /// destructor
76 ~Keys(); 76 ~Keys();
77
78 /**
79 Strip out modifiers we want to ignore
80 @return the cleaned state number
81 */
82 static unsigned int cleanMods(unsigned int mods)
83 //remove numlock, capslock and scrolllock
84 { return mods & (~Mod2Mask & ~Mod5Mask & ~LockMask);}
85
86 unsigned int keycodeToModmask(unsigned int keycode);
87 void loadModmap();
88
77 /** 89 /**
78 Load configuration from file 90 Load configuration from file
79 @return true on success, else false 91 @return true on success, else false
@@ -170,8 +182,6 @@ private:
170 /// debug function 182 /// debug function
171 void showKeyTree(t_key *key, unsigned int w=0); 183 void showKeyTree(t_key *key, unsigned int w=0);
172#endif //DEBUG 184#endif //DEBUG
173 /// determine key modifier maps for caps-, num- and scrolllock
174 void determineModmap();
175 185
176 struct t_actionstr{ 186 struct t_actionstr{
177 const char *string; 187 const char *string;
@@ -187,6 +197,7 @@ private:
187 std::string m_execcmdstring; ///< copy of the execcommandstring 197 std::string m_execcmdstring; ///< copy of the execcommandstring
188 int m_param; ///< copy of the param argument 198 int m_param; ///< copy of the param argument
189 Display *m_display; ///< display connection 199 Display *m_display; ///< display connection
200 XModifierKeymap *m_modmap; // Modifier->keycode mapping
190}; 201};
191 202
192#endif // _KEYS_HH_ 203#endif // _KEYS_HH_