mirror of
https://github.com/markqvist/NomadNet.git
synced 2025-02-22 08:00:00 -05:00
Improved sync UI
This commit is contained in:
parent
0bd7a9bdf5
commit
698b97f78c
@ -287,7 +287,8 @@ class NomadNetworkApp:
|
||||
RNS.log("Could not recall identity for autoselected LXMF propagation node "+RNS.prettyhexrep(selected_node.source_hash), RNS.LOG_WARNING)
|
||||
RNS.log("LXMF propagation will not be available until a trusted node announces on the network.", RNS.LOG_WARNING)
|
||||
|
||||
|
||||
def get_default_propagation_node(self):
|
||||
return self.message_router.get_outbound_propagation_node()
|
||||
|
||||
def save_peer_settings(self):
|
||||
file = open(self.peersettingspath, "wb")
|
||||
|
@ -358,14 +358,26 @@ class ConversationsDisplay():
|
||||
button_columns = urwid.Columns([("weight", 0.45, sync_button), ("weight", 0.1, urwid.Text("")), ("weight", 0.45, cancel_button)])
|
||||
real_sync_button.bc = button_columns
|
||||
|
||||
dialog = DialogLineBox(
|
||||
urwid.Pile([
|
||||
urwid.Text(""),
|
||||
sync_progress,
|
||||
urwid.Text(""),
|
||||
button_columns
|
||||
]), title="Message Sync"
|
||||
)
|
||||
if self.app.get_default_propagation_node() != None:
|
||||
dialog = DialogLineBox(
|
||||
urwid.Pile([
|
||||
urwid.Text(""),
|
||||
sync_progress,
|
||||
urwid.Text(""),
|
||||
button_columns
|
||||
]), title="Message Sync"
|
||||
)
|
||||
else:
|
||||
button_columns = urwid.Columns([("weight", 0.45, urwid.Text("" )), ("weight", 0.1, urwid.Text("")), ("weight", 0.45, cancel_button)])
|
||||
dialog = DialogLineBox(
|
||||
urwid.Pile([
|
||||
urwid.Text(""),
|
||||
urwid.Text("No trusted nodes found, cannot sync", align="center"),
|
||||
urwid.Text(""),
|
||||
button_columns
|
||||
]), title="Message Sync"
|
||||
)
|
||||
|
||||
dialog.delegate = self
|
||||
dialog.sync_progress = sync_progress
|
||||
dialog.cancel_button = cancel_button
|
||||
|
Loading…
x
Reference in New Issue
Block a user