Skip to content

Commit bab075c

Browse files
fix regresssion in pasted returns and spaces from input refactor
1 parent 5b27b88 commit bab075c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

bpython/curtsiesfrontend/repl.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -581,13 +581,15 @@ def only_whitespace_left_of_cursor():
581581
self.cursor_offset, self.current_line = self.matches_iter.cur_line()
582582

583583
def process_simple_event(self, e):
584-
if e in ("\n", "\r", "PAD_ENTER"):
584+
if e in (u"<Ctrl-j>", u"<Ctrl-m>", u"<PADENTER>"):
585585
self.on_enter()
586586
while self.fake_refresh_requested:
587587
self.fake_refresh_requested = False
588588
self.process_event(events.RefreshRequestEvent())
589589
elif isinstance(e, events.Event):
590590
pass # ignore events
591+
elif e == '<SPACE>':
592+
self.add_normal_character(' ')
591593
else:
592594
self.add_normal_character(e)
593595

0 commit comments

Comments
 (0)