Commit 226e08a1 authored by Philipp Hörist's avatar Philipp Hörist
Browse files

ChatControlBase: Simplify code

parent 68ab106f
......@@ -922,9 +922,7 @@ def _on_message_textview_key_press_event(self, textview, event):
else: # Ctrl+Down
self.scroll_messages('down', message_buffer, 'sent')
return True
elif (event.keyval == Gdk.KEY_Return or
event.keyval == Gdk.KEY_KP_Enter): # ENTER
elif event.keyval in (Gdk.KEY_Return, Gdk.KEY_KP_Enter): # ENTER
if event_state & Gdk.ModifierType.SHIFT_MASK:
textview.insert_newline()
return True
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment