Fix input mask bitwise operations. Thanks to Kees Cook
This commit is contained in:
parent
87c9bdef6d
commit
eeb91b4c6f
|
@ -239,8 +239,9 @@ class TerminatorTerm:
|
||||||
|
|
||||||
def on_vte_key_press (self, term, event):
|
def on_vte_key_press (self, term, event):
|
||||||
keyname = gtk.gdk.keyval_name (event.keyval)
|
keyname = gtk.gdk.keyval_name (event.keyval)
|
||||||
|
mask = gtk.gdk.CONTROL_MASK | gtk.gdk.SHIFT_MASK
|
||||||
|
|
||||||
if event.state & (gtk.gdk.CONTROL_MASK | gtk.gdk.SHIFT_MASK):
|
if (event.state & mask) == mask:
|
||||||
if keyname == 'N':
|
if keyname == 'N':
|
||||||
self.term.go_next (self)
|
self.term.go_next (self)
|
||||||
return (True)
|
return (True)
|
||||||
|
|
Loading…
Reference in New Issue