summaryrefslogtreecommitdiffstats
path: root/source/x11-helper.c
diff options
context:
space:
mode:
authorDave Davenport <qball@gmpclient.org>2016-09-02 18:19:16 +0200
committerDave Davenport <qball@gmpclient.org>2016-09-02 18:19:16 +0200
commit4379f3be7c9f1a822977543435dbe60381ab45fe (patch)
tree7d3dc2c057510c002eae8387d4f5bbf3ea18f293 /source/x11-helper.c
parentb420db8d301f90808a5b36e8bdcb8a27f00a8fb4 (diff)
Ctrl-click does alternate accept entry.
Fixes #429
Diffstat (limited to 'source/x11-helper.c')
-rw-r--r--source/x11-helper.c16
1 files changed, 5 insertions, 11 deletions
diff --git a/source/x11-helper.c b/source/x11-helper.c
index c51c3e66..096d82d4 100644
--- a/source/x11-helper.c
+++ b/source/x11-helper.c
@@ -68,17 +68,6 @@ struct _xcb_stuff xcb_int = {
};
xcb_stuff *xcb = &xcb_int;
-enum
-{
- X11MOD_SHIFT,
- X11MOD_CONTROL,
- X11MOD_ALT,
- X11MOD_META,
- X11MOD_SUPER,
- X11MOD_HYPER,
- X11MOD_ANY,
- NUM_X11MOD
-};
xcb_depth_t *depth = NULL;
xcb_visualtype_t *visual = NULL;
@@ -598,6 +587,11 @@ static void x11_figure_out_masks ( xkb_stuff *xkb )
}
}
+int x11_modifier_active ( unsigned int mask, int key )
+{
+ return (x11_mod_masks[key]&mask) != 0;
+}
+
unsigned int x11_canonalize_mask ( unsigned int mask )
{
// Bits 13 and 14 of the modifiers together are the group number, and