Adhoc: Show location directly in the server list

This commit is contained in:
Henrik Rydgård committed 2026-03-09 00:53:39 +01:00
1 parent 71d884379d
commit 9373791bc4
1 file changed
+7 -1
+7 -1
View File
@@ -134,7 +134,13 @@ AdhocServerRow::AdhocServerRow(std::string *value, const AdhocServerListEntry &e
LinearLayout *lines = Add(new LinearLayout(ORIENT_VERTICAL, new LinearLayoutParams(Margins(5, 5))));
lines->SetSpacing(0.0f);
lines->Add(new TextView(entry.name));
lines->Add(new TextView(entry.host))->SetTextSize(TextSize::Small)->SetWordWrap();
std::string secondLine = entry.host;
if (!entry.location.empty()) {
secondLine += ": " + entry.location;
}
lines->Add(new TextView(secondLine))->SetTextSize(TextSize::Small)->SetWordWrap();
Add(new Spacer(0.0f, new LinearLayoutParams(1.0f, Margins(0.0f, 5.0f))));