mirror of
https://github.com/markqvist/Sideband.git
synced 2024-12-30 09:56:11 -05:00
Improved message detail rendering
This commit is contained in:
parent
69378e7dd4
commit
3cecf5e259
@ -201,11 +201,11 @@ class Messages():
|
|||||||
if "euclidian" in d:
|
if "euclidian" in d:
|
||||||
edst = d["euclidian"]
|
edst = d["euclidian"]
|
||||||
if edst != None:
|
if edst != None:
|
||||||
rcvd_d_str = " [b]Distance[/b] "+RNS.prettydistance(edst)
|
rcvd_d_str = "\n[b]Distance[/b] "+RNS.prettydistance(edst)
|
||||||
elif "geodesic" in d:
|
elif "geodesic" in d:
|
||||||
gdst = d["geodesic"]
|
gdst = d["geodesic"]
|
||||||
if gdst != None:
|
if gdst != None:
|
||||||
rcvd_d_str = " [b]Distance[/b] "+RNS.prettydistance(gdst)
|
rcvd_d_str = "\n[b]Distance[/b] "+RNS.prettydistance(gdst) + " (geodesic)"
|
||||||
|
|
||||||
phy_stats_str = ""
|
phy_stats_str = ""
|
||||||
if "extras" in m and m["extras"] != None:
|
if "extras" in m and m["extras"] != None:
|
||||||
@ -266,13 +266,12 @@ class Messages():
|
|||||||
if phy_stats_str != "" and self.app.sideband.config["advanced_stats"]:
|
if phy_stats_str != "" and self.app.sideband.config["advanced_stats"]:
|
||||||
heading_str += phy_stats_str+"\n"
|
heading_str += phy_stats_str+"\n"
|
||||||
|
|
||||||
heading_str += "[b]Received[/b] "+rxstr
|
heading_str += "[b]Sent[/b] "+txstr
|
||||||
|
heading_str += "\n[b]Received[/b] "+rxstr
|
||||||
|
|
||||||
if rcvd_d_str != "" and self.app.sideband.config["advanced_stats"]:
|
if rcvd_d_str != "":
|
||||||
heading_str += rcvd_d_str
|
heading_str += rcvd_d_str
|
||||||
|
|
||||||
heading_str += "\n[b]Sent[/b] "+txstr
|
|
||||||
|
|
||||||
item = ListLXMessageCard(
|
item = ListLXMessageCard(
|
||||||
text=m["content"].decode("utf-8"),
|
text=m["content"].decode("utf-8"),
|
||||||
heading=heading_str,
|
heading=heading_str,
|
||||||
|
Loading…
Reference in New Issue
Block a user