Browse Source

kivy: simplify parse_URI

283
ThomasV 9 years ago
parent
commit
c57ed0c212
  1. 2
      gui/kivy/main_window.py
  2. 7
      gui/kivy/uix/screens.py

2
gui/kivy/main_window.py

@ -232,7 +232,7 @@ class ElectrumWindow(App):
try:
url = electrum.util.parse_URI(url, self.on_pr)
except:
self.show_info("Invalid URI", url)
self.show_info(_("Not a Bitcoin URI") + ':\n', url)
return
self.send_screen.set_URI(url)

7
gui/kivy/uix/screens.py

@ -230,12 +230,7 @@ class SendScreen(CScreen):
if not contents:
self.app.show_info(_("Clipboard is empty"))
return
try:
uri = parse_URI(contents)
except:
self.app.show_info(_("Clipboard content is not a Bitcoin URI"))
return
self.set_URI(uri)
self.app.set_URI(contents)
def do_send(self):
if self.payment_request:

Loading…
Cancel
Save