mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-01-25 22:16:14 -05:00
Changed content of table
Changed the columns of the table to be more useful
This commit is contained in:
parent
2b045ffca6
commit
110b40ea49
@ -60,10 +60,19 @@ void RecentEntriesTable<AircraftRecentEntries>::draw(
|
|||||||
|
|
||||||
std::string entry_string = "\x1B";
|
std::string entry_string = "\x1B";
|
||||||
entry_string += aged_color;
|
entry_string += aged_color;
|
||||||
|
#if false
|
||||||
entry_string += to_string_hex(entry.ICAO_address, 6) + " " +
|
entry_string += to_string_hex(entry.ICAO_address, 6) + " " +
|
||||||
entry.callsign + " " +
|
entry.callsign + " " +
|
||||||
(entry.hits <= 999 ? to_string_dec_uint(entry.hits, 4) : "999+") + " " +
|
(entry.hits <= 999 ? to_string_dec_uint(entry.hits, 4) : "999+") + " " +
|
||||||
entry.time_string;
|
entry.time_string;
|
||||||
|
#else
|
||||||
|
entry_string +=
|
||||||
|
(entry.callsign[0]!=' ' ? entry.callsign + " " : to_string_hex(entry.ICAO_address, 6) + " ") +
|
||||||
|
to_string_dec_int(entry.pos.altitude,5) + " " +
|
||||||
|
to_string_dec_int(entry.velo.speed,3) + " " +
|
||||||
|
(entry.hits <= 999 ? to_string_dec_uint(entry.hits, 3) + " " : "1k+ ") +
|
||||||
|
to_string_dec_uint(entry.age, 3);
|
||||||
|
#endif
|
||||||
|
|
||||||
painter.draw_string(
|
painter.draw_string(
|
||||||
target_rect.location(),
|
target_rect.location(),
|
||||||
|
@ -254,10 +254,18 @@ private:
|
|||||||
void on_tick_second();
|
void on_tick_second();
|
||||||
|
|
||||||
const RecentEntriesColumns columns { {
|
const RecentEntriesColumns columns { {
|
||||||
|
#if false
|
||||||
{ "ICAO", 6 },
|
{ "ICAO", 6 },
|
||||||
{ "Callsign", 9 },
|
{ "Callsign", 9 },
|
||||||
{ "Hits", 4 },
|
{ "Hits", 4 },
|
||||||
{ "Time", 8 }
|
{ "Time", 8 }
|
||||||
|
#else
|
||||||
|
{ "ICAO/Call", 9 },
|
||||||
|
{ "Alt", 6 },
|
||||||
|
{ "Spd", 4 },
|
||||||
|
{ "Hits", 4 },
|
||||||
|
{ "Age", 4 }
|
||||||
|
#endif
|
||||||
} };
|
} };
|
||||||
AircraftRecentEntries recent { };
|
AircraftRecentEntries recent { };
|
||||||
RecentEntriesView<RecentEntries<AircraftRecentEntry>> recent_entries_view { columns, recent };
|
RecentEntriesView<RecentEntries<AircraftRecentEntry>> recent_entries_view { columns, recent };
|
||||||
|
Loading…
x
Reference in New Issue
Block a user