Browse Source

enable gui switch button (classic <-> lite) both ways

283
thomasv 12 years ago
parent
commit
e9e117712a
  1. 15
      lib/gui_lite.py
  2. 4
      lib/gui_qt.py

15
lib/gui_lite.py

@ -302,15 +302,18 @@ class MiniWindow(QDialog):
self.receive_button.setObjectName("receive_button")
self.receive_button.setDefault(True)
main_layout = QGridLayout(self)
self.switch_button = QPushButton( QIcon(":icons/switchgui.png"),'' )
self.switch_button.clicked.connect(expand_callback)
main_layout.addWidget(self.balance_label, 0, 0)
main_layout.addWidget(self.receive_button, 0, 1)
main_layout = QGridLayout(self)
main_layout.addWidget(self.address_input, 1, 0)
main_layout.addWidget(self.switch_button, 0, 0)
main_layout.addWidget(self.balance_label, 0, 1)
main_layout.addWidget(self.receive_button, 0, 2)
main_layout.addWidget(self.amount_input, 2, 0)
main_layout.addWidget(self.send_button, 2, 1)
main_layout.addWidget(self.address_input, 1, 0, 1, 3)
main_layout.addWidget(self.amount_input, 2, 0, 1, 2)
main_layout.addWidget(self.send_button, 2, 2)
self.history_list = history_widget.HistoryWidget()
self.history_list.setObjectName("history")

4
lib/gui_qt.py

@ -1158,8 +1158,8 @@ class ElectrumWindow(QMainWindow):
sb = QStatusBar()
sb.setFixedHeight(35)
qtVersion = qVersion()
# if (int(qtVersion[0]) >= 4 and int(qtVersion[2]) >= 7):
# sb.addPermanentWidget( StatusBarButton( QIcon(":icons/switchgui.png"), "Switch to Lite Mode", self.go_lite ) )
if (int(qtVersion[0]) >= 4 and int(qtVersion[2]) >= 7):
sb.addPermanentWidget( StatusBarButton( QIcon(":icons/switchgui.png"), "Switch to Lite Mode", self.go_lite ) )
if self.wallet.seed:
sb.addPermanentWidget( StatusBarButton( QIcon(":icons/lock.png"), "Password", lambda: self.change_password_dialog(self.wallet, self) ) )
sb.addPermanentWidget( StatusBarButton( QIcon(":icons/preferences.png"), "Preferences", self.settings_dialog ) )

Loading…
Cancel
Save