qt main window: statusbar: swap Tor and Network buttons
I think it's nicer for the network status to be rightmost, which was the case for a long time.
(Though plugins are still added after (via multiple different mechanisms, see 2fa, hww, revealer).
We could perhaps add a VLine separator, or add them to the left instead.)
follow-up 90d1d587e8
This commit is contained in:
@@ -1648,12 +1648,23 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, Logger, QtEventListener):
|
|||||||
self.status_button = None
|
self.status_button = None
|
||||||
self.tor_button = None
|
self.tor_button = None
|
||||||
if self.network:
|
if self.network:
|
||||||
self.status_button = StatusBarButton(read_QIcon("status_disconnected.png"), _("Network"), self.gui_object.show_network_dialog, sb_height)
|
self.tor_button = StatusBarButton(
|
||||||
sb.addPermanentWidget(self.status_button)
|
read_QIcon("tor_logo.png"),
|
||||||
self.tor_button = StatusBarButton(read_QIcon("tor_logo.png"), _("TOR"),
|
_("Tor"),
|
||||||
self.gui_object.show_network_dialog, sb_height)
|
self.gui_object.show_network_dialog,
|
||||||
|
sb_height,
|
||||||
|
)
|
||||||
sb.addPermanentWidget(self.tor_button)
|
sb.addPermanentWidget(self.tor_button)
|
||||||
self.tor_button.setVisible(False)
|
self.tor_button.setVisible(False)
|
||||||
|
# add status btn last, to place it at rightmost pos
|
||||||
|
self.status_button = StatusBarButton(
|
||||||
|
read_QIcon("status_disconnected.png"),
|
||||||
|
_("Network"),
|
||||||
|
self.gui_object.show_network_dialog,
|
||||||
|
sb_height,
|
||||||
|
)
|
||||||
|
sb.addPermanentWidget(self.status_button)
|
||||||
|
# add plugins
|
||||||
run_hook('create_status_bar', sb)
|
run_hook('create_status_bar', sb)
|
||||||
self.setStatusBar(sb)
|
self.setStatusBar(sb)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user