1
0

misc python3 updates:

- use jsonrpclib-pelix
 - update the kivy gui
 - update plugins
This commit is contained in:
ThomasV
2017-02-16 10:54:24 +01:00
parent e562b0b565
commit c3388d9677
32 changed files with 130 additions and 129 deletions

View File

@@ -46,6 +46,7 @@ class ChoiceDialog(Factory.Popup):
def __init__(self, title, choices, key, callback):
Factory.Popup.__init__(self)
print(choices, type(choices))
if type(choices) is list:
choices = dict(map(lambda x: (x,x), choices))
layout = self.ids.choices

View File

@@ -14,15 +14,14 @@ from kivy.core.window import Window
from kivy.clock import Clock
from kivy.utils import platform
from electrum_gui.kivy.uix.dialogs import EventsDialog
from electrum_gui.kivy.i18n import _
from electrum.base_wizard import BaseWizard
from password_dialog import PasswordDialog
from . import EventsDialog
from ...i18n import _
from .password_dialog import PasswordDialog
# global Variables
app = App.get_running_app()
is_test = (platform == "linux")
test_seed = "time taxi field recycle tiny license olive virus report rare steel portion achieve"
test_xpub = "xpub661MyMwAqRbcEbvVtRRSjqxVnaWVUMewVzMiURAKyYratih4TtBpMypzzefmv8zUNebmNVzB3PojdC5sV2P9bDgMoo9B3SARw1MXUUfU1GL"
@@ -429,7 +428,7 @@ class WizardDialog(EventsDialog):
crcontent = ObjectProperty(None)
def __init__(self, wizard, **kwargs):
super(WizardDialog, self).__init__(**kwargs)
super(WizardDialog, self).__init__()
self.wizard = wizard
self.ids.back.disabled = not wizard.can_go_back()
self.app = App.get_running_app()
@@ -624,9 +623,7 @@ class RestoreSeedDialog(WizardDialog):
def get_text(self):
ti = self.ids.text_input_seed
text = unicode(ti.text).strip()
text = ' '.join(text.split())
return text
return ' '.join(ti.text.strip().split())
def update_text(self, c):
c = c.lower()
@@ -752,6 +749,7 @@ class InstallWizard(BaseWizard, Widget):
# on completion hide message
Clock.schedule_once(lambda dt: app.info_bubble.hide(now=True), -1)
app = App.get_running_app()
app.show_info_bubble(
text=msg, icon='atlas://gui/kivy/theming/light/important',
pos=Window.center, width='200sp', arrow_pos=None, modal=True)
@@ -793,6 +791,7 @@ class InstallWizard(BaseWizard, Widget):
def show_xpub_dialog(self, **kwargs): ShowXpubDialog(self, **kwargs).open()
def show_error(self, msg):
app = App.get_running_app()
Clock.schedule_once(lambda dt: app.show_error(msg))
def password_dialog(self, message, callback):

View File

@@ -10,7 +10,7 @@ from electrum.plugins import run_hook
from electrum import coinchooser
from electrum.util import fee_levels
from choice_dialog import ChoiceDialog
from .choice_dialog import ChoiceDialog
Builder.load_string('''
#:import partial functools.partial

View File

@@ -1,13 +1,14 @@
import os
from kivy.app import App
from kivy.factory import Factory
from kivy.properties import ObjectProperty
from kivy.lang import Builder
from electrum_gui.kivy.i18n import _
from electrum.util import base_units
import os
from label_dialog import LabelDialog
from ...i18n import _
from .label_dialog import LabelDialog
Builder.load_string('''
#:import os os