Fix tooltip string parameters, change function signatures to match upstream
This commit is contained in:
@@ -3171,7 +3171,7 @@ struct IndustryCargoesWindow : public Window {
|
||||
|
||||
case CFT_INDUSTRY:
|
||||
if (fld->u.industry.ind_type < NUM_INDUSTRYTYPES && (this->ind_cargo >= NUM_INDUSTRYTYPES || fieldxy.x != 2)) {
|
||||
GuiShowTooltips(this, STR_INDUSTRY_CARGOES_INDUSTRY_TOOLTIP, 0, nullptr, close_cond);
|
||||
GuiShowTooltips(this, STR_INDUSTRY_CARGOES_INDUSTRY_TOOLTIP, close_cond);
|
||||
}
|
||||
return true;
|
||||
|
||||
@@ -3180,9 +3180,8 @@ struct IndustryCargoesWindow : public Window {
|
||||
}
|
||||
if (cid != INVALID_CARGO && (this->ind_cargo < NUM_INDUSTRYTYPES || cid != this->ind_cargo - NUM_INDUSTRYTYPES)) {
|
||||
const CargoSpec *csp = CargoSpec::Get(cid);
|
||||
uint64 params[5];
|
||||
params[0] = csp->name;
|
||||
GuiShowTooltips(this, STR_INDUSTRY_CARGOES_CARGO_TOOLTIP, 1, params, close_cond);
|
||||
SetDParam(0, csp->name);
|
||||
GuiShowTooltips(this, STR_INDUSTRY_CARGOES_CARGO_TOOLTIP, close_cond, 1);
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -3351,6 +3350,6 @@ void ShowIndustryTooltip(Window *w, const TileIndex tile)
|
||||
|
||||
if (!msg.empty()) {
|
||||
_temp_special_strings[0] = std::move(msg);
|
||||
GuiShowTooltips(w, SPECSTR_TEMP_START, 0, nullptr, TCC_HOVER_VIEWPORT);
|
||||
GuiShowTooltips(w, SPECSTR_TEMP_START, TCC_HOVER_VIEWPORT);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user