kivy: fix ln channel open via scan_qr

This commit is contained in:
SomberNight 2019-09-05 17:06:42 +02:00
parent 45f3e28d38
commit 0deb12cb2b
No known key found for this signature in database
GPG key ID: B33B5F232C6271E9

View file

@ -71,7 +71,7 @@ Builder.load_string('''
icon: 'atlas://electrum/gui/kivy/theming/light/camera'
size_hint: 0.5, None
height: '48dp'
on_release: app.scan_qr(on_complete=s.on_pubkey)
on_release: app.scan_qr(on_complete=s.on_qr)
Button:
text: _('Suggest')
size_hint: 1, None
@ -122,6 +122,9 @@ class LightningOpenChannelDialog(Factory.Popup):
return
self.pubkey = contents
def on_qr(self, conn_str):
self.pubkey = conn_str
def open_channel(self):
if not self.pubkey or not self.amount:
self.app.show_info(_('All fields must be filled out'))