aboutsummaryrefslogtreecommitdiffstats
path: root/src/bin
diff options
context:
space:
mode:
authorBoris Faure <billiob@gmail.com>2014-10-03 20:59:38 +0200
committerBoris Faure <billiob@gmail.com>2014-10-03 20:59:38 +0200
commit585d4c55ec82ecc6f49f211b9f32d5e5dd9fa89f (patch)
treeb457a5d7bf7cd3eb32ec9b1ae60933abd29725d6 /src/bin
parentrestrict modifiers used on key-bindings. Should fix T1695 (diff)
downloadterminology-585d4c55ec82ecc6f49f211b9f32d5e5dd9fa89f.tar.gz
forbid AltGr in keybindings
Diffstat (limited to 'src/bin')
-rw-r--r--src/bin/keyin.c2
-rw-r--r--src/bin/options_keys.c3
2 files changed, 4 insertions, 1 deletions
diff --git a/src/bin/keyin.c b/src/bin/keyin.c
index 85b06ba..5e79ef2 100644
--- a/src/bin/keyin.c
+++ b/src/bin/keyin.c
@@ -221,6 +221,7 @@ keyin_handle(Keys_Handler *khdl, Termpty *ty, const Evas_Event_Key_Down *ev,
if (!evas_key_modifier_is_set(ev->modifiers, "Meta") &&
!evas_key_modifier_is_set(ev->modifiers, "Hyper") &&
+ !evas_key_modifier_is_set(ev->modifiers, "AltGr") &&
!evas_key_modifier_is_set(ev->modifiers, "ISO_Level3_Shift"))
{
Key_Binding *kb;
@@ -313,6 +314,7 @@ key_is_modifier(const char *key)
STATIC_STR_EQUAL("Shift") ||
STATIC_STR_EQUAL("Control") ||
STATIC_STR_EQUAL("Alt") ||
+ STATIC_STR_EQUAL("AltGr") ||
STATIC_STR_EQUAL("Meta") ||
STATIC_STR_EQUAL("Super") ||
STATIC_STR_EQUAL("Hyper") ||
diff --git a/src/bin/options_keys.c b/src/bin/options_keys.c
index 65bb79a..cee8cff 100644
--- a/src/bin/options_keys.c
+++ b/src/bin/options_keys.c
@@ -90,9 +90,10 @@ _cb_key_up(void *data, Evas *e EINA_UNUSED,
if (evas_key_modifier_is_set(ev->modifiers, "Meta") ||
evas_key_modifier_is_set(ev->modifiers, "Hyper") ||
+ evas_key_modifier_is_set(ev->modifiers, "AltGr") ||
evas_key_modifier_is_set(ev->modifiers, "ISO_Level3_Shift"))
{
- ERR("Modifiers Meta/Hyper/ISO_Level3_Shift are not supported in keybindings");
+ ERR("Modifiers Meta/Hyper/ISO_Level3_Shift/AltGr are not supported in keybindings");
return;
}