diff --git a/nomadnet/_version.py b/nomadnet/_version.py index 7d53ea3..71eb32d 100644 --- a/nomadnet/_version.py +++ b/nomadnet/_version.py @@ -1 +1 @@ -__version__ = "0.0.7" \ No newline at end of file +__version__ = "0.0.8" \ No newline at end of file diff --git a/nomadnet/ui/textui/Browser.py b/nomadnet/ui/textui/Browser.py index c9465c1..c259c37 100644 --- a/nomadnet/ui/textui/Browser.py +++ b/nomadnet/ui/textui/Browser.py @@ -101,7 +101,8 @@ class Browser: self.frame = BrowserFrame(self.browser_body, header=self.browser_header, footer=self.browser_footer) self.frame.delegate = self - self.display_widget = urwid.AttrMap(urwid.LineBox(self.frame, title="Remote Node"), "inactive_text") + self.linebox = urwid.LineBox(self.frame, title="Remote Node") + self.display_widget = urwid.AttrMap(self.linebox, "inactive_text") def make_status_widget(self): if self.response_progress > 0: @@ -146,9 +147,11 @@ class Browser: self.browser_body = urwid.Filler(urwid.Text("Disconnected\n"+self.g["arrow_l"]+" "+self.g["arrow_r"], align="center"), "middle") self.browser_footer = urwid.Text("") self.browser_header = urwid.Text("") + self.linebox.set_title("Remote Node") else: self.display_widget.set_attr_map({None: "body_text"}) self.browser_header = self.make_control_widget() + self.linebox.set_title(self.app.directory.simplest_display_str(self.destination_hash)) if self.status == Browser.DONE: self.browser_footer = self.make_status_widget() @@ -332,11 +335,14 @@ class Browser: timeout = self.timeout ) - self.last_request_receipt = receipt - self.last_request_id = receipt.request_id + if receipt: + self.last_request_receipt = receipt + self.last_request_id = receipt.request_id + self.status = Browser.REQUEST_SENT + self.update_display() + else: + self.link.teardown() - self.status = Browser.REQUEST_SENT - self.update_display() def link_established(self, link): diff --git a/nomadnet/ui/textui/Conversations.py b/nomadnet/ui/textui/Conversations.py index c7192ec..d804c6e 100644 --- a/nomadnet/ui/textui/Conversations.py +++ b/nomadnet/ui/textui/Conversations.py @@ -559,7 +559,7 @@ class ConversationWidget(urwid.WidgetWrap): if allowed: self.frame.contents["footer"] = (self.minimal_editor, None) else: - warning = urwid.AttrMap(urwid.Padding(urwid.Text(g["info"]+" You cannot currently communicate with this peer, since it's identity keys are unknown", align="center")), "msg_header_caution") + warning = urwid.AttrMap(urwid.Padding(urwid.Text(g["info"]+" You cannot currently communicate with this peer, since it's identity keys are not known", align="center")), "msg_header_caution") self.frame.contents["footer"] = (warning, None) def toggle_focus_area(self):