52 static char* filter_name[] = {
58 static char* commit_name =
"Commit";
59 static char* cancel_name =
"Cancel";
61 static Color commit_color(53,159,67);
62 static Color cancel_color(160,8,8);
82 :
FormWindow(s, 0, 0, s->Width(), s->Height()), manager(mgr),
83 loc_labels(0), dst_labels(0), loc_data(0), dst_data(0),
85 nav_edit_mode(NAV_EDIT_NONE), star_map(0), map_win(0),
86 star_system(0), ship(0), mission(0), editor(false)
109 for (i = 0; i < 3; i++) {
122 for (i = 0; i < 6; i++) {
199 switch (star->
Type()) {
255 for (
int i = 0; i < 6; i++)
317 bool updated =
false;
362 strcpy_s(loc_buf,
Game::GetText(
"NavDlg.loc-labels").data());
366 sprintf_s(loc_buf,
"\n%s\n%s\n%s, %s, %s",
373 sprintf_s(loc_buf,
"\n%s\nPlanck Space?\n%s, %s, %s",
404 if (navpt && navpt->
Region()) {
420 strcpy_s(loc_buf,
Game::GetText(
"NavDlg.dst-labels").data());
423 sprintf_s(loc_buf,
"\n%s\n%s\n%s, %s, %s\n%s",
474 int use_filter_mode = -1;
498 if (use_filter_mode >= 0) {
499 for (
int i = 0; i < 6; i++) {
500 if (i == use_filter_mode)
515 int filter_index = -1;
516 for (
int i = 0; i < 6; i++) {
526 if (filter_index >= 0)
545 if (mode >= 0 && mode < 3) {
546 int use_filter_mode = -1;
558 else if (mode == 1) {
564 else if (mode == 2) {
570 if (use_filter_mode >= 0) {
571 for (
int i = 0; i < 6; i++) {
590 if (iter.
value() == star) {
613 if (iter.
value() == planet) {
636 if (iter.
value() == rgn) {
705 sprintf_s(units,
" %s",
Game::GetText(
"NavDlg.units.seconds").data());
709 sprintf_s(units,
" %s",
Game::GetText(
"NavDlg.units.minutes").data());
711 else if (p < 24 * 3600) {
713 sprintf_s(units,
" %s",
Game::GetText(
"NavDlg.units.hours").data());
715 else if (p < 365.25 * 24 * 3600) {
717 sprintf_s(units,
" %s",
Game::GetText(
"NavDlg.units.days").data());
721 sprintf_s(units,
" %s",
Game::GetText(
"NavDlg.units.years").data());
729 strcat_s(radius, units_km.
data());
730 strcat_s(mass, units_tonnes.
data());
731 strcat_s(orbit, units_km.
data());
732 strcat_s(period, units);
772 strcat_s(range, units_km.
data());
801 strcpy_s(range,
"0");
803 strcat_s(range, units_km.
data());
924 bool visible = s->
GetIFF() == 0 ||
1043 static DWORD click_time = 0;
1053 if (elem && msn_elem_dlg) {