summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPietro Gagliardi <[email protected]>2014-08-14 18:55:54 -0400
committerPietro Gagliardi <[email protected]>2014-08-14 18:55:54 -0400
commit63981722cff3e592cdc075a735ca0a3657b331b8 (patch)
tree8b95e1d89a88fd7a69b8f6878b40628d4dd11704
parent5ca3f0f0f9ccdb9fd2301e0b8b7503302c1b83c4 (diff)
Resolved Alt key woes on GTK+.
-rw-r--r--redo/area_unix.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/redo/area_unix.go b/redo/area_unix.go
index 94cda2e..7c3829e 100644
--- a/redo/area_unix.go
+++ b/redo/area_unix.go
@@ -146,7 +146,10 @@ func makeModifiers(state C.guint) (m Modifiers) {
if (state & C.GDK_CONTROL_MASK) != 0 {
m |= Ctrl
}
- if (state & C.GDK_META_MASK) != 0 { // TODO get equivalent for Alt
+ if (state & C.GDK_META_MASK) != 0 {
+ m |= Alt
+ }
+ if (state & C.GDK_MOD1_MASK) != 0 { // GTK+ itself requires this to be Alt (just read through gtkaccelgroup.c)
m |= Alt
}
if (state & C.GDK_SHIFT_MASK) != 0 {