Paste clipboard when using shift-insert in prompts

This commit is contained in:
Florian Bruhin 2017-03-29 16:17:43 +02:00
parent 7dba877354
commit 64feb62fb1

View File

@ -48,11 +48,10 @@ class MinimalLineEditMixin:
try: try:
text = utils.get_clipboard(selection=True) text = utils.get_clipboard(selection=True)
except utils.ClipboardError: except utils.ClipboardError:
pass text = utils.get_clipboard()
else: e.accept()
e.accept() self.insert(text)
self.insert(text) return
return
super().keyPressEvent(e) super().keyPressEvent(e)
def __repr__(self): def __repr__(self):