(svn r13712) -Fix: enforce the length restrictions of company and president name in the commands too.

This commit is contained in:
rubidium
2008-07-17 11:19:20 +00:00
parent 7c531c4ece
commit 03afcec36f
6 changed files with 12 additions and 5 deletions

View File

@@ -1252,13 +1252,13 @@ struct PlayerCompanyWindow : Window
case PCW_WIDGET_PRESIDENT_NAME:
this->query_widget = PCW_WIDGET_PRESIDENT_NAME;
SetDParam(0, this->window_number);
ShowQueryString(STR_PLAYER_NAME, STR_700B_PRESIDENT_S_NAME, 31, 94, this, CS_ALPHANUMERAL);
ShowQueryString(STR_PLAYER_NAME, STR_700B_PRESIDENT_S_NAME, MAX_LENGTH_PRESIDENT_NAME, 94, this, CS_ALPHANUMERAL);
break;
case PCW_WIDGET_COMPANY_NAME:
this->query_widget = PCW_WIDGET_COMPANY_NAME;
SetDParam(0, this->window_number);
ShowQueryString(STR_COMPANY_NAME, STR_700A_COMPANY_NAME, 31, 150, this, CS_ALPHANUMERAL);
ShowQueryString(STR_COMPANY_NAME, STR_700A_COMPANY_NAME, MAX_LENGTH_COMPANY_NAME, 150, this, CS_ALPHANUMERAL);
break;
case PCW_WIDGET_BUILD_VIEW_HQ: {