(svn r25714) -Fix: explicitly cast some things to silence warnings on GCC 4.0

This commit is contained in:
fonsinchen
2013-08-10 12:47:24 +00:00
parent fd16b0c65c
commit 0baa72aff9
6 changed files with 15 additions and 15 deletions

View File

@@ -2583,7 +2583,7 @@ struct IndustryCargoesWindow : public Window {
delete lst;
break;
}
int selected = (this->ind_cargo >= NUM_INDUSTRYTYPES) ? this->ind_cargo - NUM_INDUSTRYTYPES : -1;
int selected = (this->ind_cargo >= NUM_INDUSTRYTYPES) ? (int)(this->ind_cargo - NUM_INDUSTRYTYPES) : -1;
ShowDropDownList(this, lst, selected, WID_IC_CARGO_DROPDOWN, 0, true);
break;
}
@@ -2600,7 +2600,7 @@ struct IndustryCargoesWindow : public Window {
delete lst;
break;
}
int selected = (this->ind_cargo < NUM_INDUSTRYTYPES) ? this->ind_cargo : -1;
int selected = (this->ind_cargo < NUM_INDUSTRYTYPES) ? (int)this->ind_cargo : -1;
ShowDropDownList(this, lst, selected, WID_IC_IND_DROPDOWN, 0, true);
break;
}