1
0

call init_qt everytime a plugin is enabled

This commit is contained in:
ThomasV
2014-09-04 15:45:03 +02:00
parent a8f0e4310f
commit 6101abda5d
4 changed files with 26 additions and 33 deletions

View File

@@ -467,6 +467,9 @@ class ElectrumWindow(QMainWindow):
raise Exception('Unknown base unit')
def update_status(self):
if not self.wallet:
return
if self.network is None or not self.network.is_running():
text = _("Offline")
icon = QIcon(":icons/status_disconnected.png")
@@ -2719,7 +2722,13 @@ class ElectrumWindow(QMainWindow):
w.setLayout(grid)
def do_toggle(cb, p, w):
r = p.toggle()
if p.is_enabled():
if p.disable():
p.close()
else:
if p.enable():
p.init_qt(self.gui_object)
r = p.is_enabled()
cb.setChecked(r)
if w: w.setEnabled(r)