(svn r13060) -Codechange: update build industry window when raw_industry_construction setting is modified

This commit is contained in:
glx
2008-05-12 14:54:33 +00:00
parent cffb7a834c
commit 18c33e1569
2 changed files with 66 additions and 38 deletions

View File

@@ -1147,6 +1147,12 @@ static int32 InvalidateStationBuildWindow(int32 p1)
return 0;
}
static int32 InvalidateBuildIndustryWindow(int32 p1)
{
InvalidateWindowData(WC_BUILD_INDUSTRY, 0);
return 0;
}
static int32 CloseSignalGUI(int32 p1)
{
if (p1 == 0) {
@@ -1488,7 +1494,7 @@ const SettingDesc _patch_settings[] = {
/***************************************************************************/
/* Economy section of the GUI-configure patches window */
SDT_BOOL(Patches, inflation, 0, 0, true, STR_CONFIG_PATCHES_INFLATION, NULL),
SDT_VAR(Patches, raw_industry_construction,SLE_UINT8,0,MS,0,0, 2, 0, STR_CONFIG_PATCHES_RAW_INDUSTRY_CONSTRUCTION_METHOD, NULL),
SDT_VAR(Patches, raw_industry_construction,SLE_UINT8,0,MS,0,0, 2, 0, STR_CONFIG_PATCHES_RAW_INDUSTRY_CONSTRUCTION_METHOD, InvalidateBuildIndustryWindow),
SDT_BOOL(Patches, multiple_industry_per_town, 0, 0, false, STR_CONFIG_PATCHES_MULTIPINDTOWN, NULL),
SDT_BOOL(Patches, same_industry_close, 0, 0, false, STR_CONFIG_PATCHES_SAMEINDCLOSE, NULL),
SDT_BOOL(Patches, bribe, 0, 0, true, STR_CONFIG_PATCHES_BRIBE, NULL),