(svn r20387) -Fix [FS#4000]: Allow the industry-chain button for non-fundable industries, and disallow for the 'many random industries'.

This commit is contained in:
alberth 2010-08-06 12:23:44 +00:00
parent d9c9ae8fcf
commit 16dfc7a04d
1 changed files with 2 additions and 1 deletions

View File

@ -259,7 +259,8 @@ class BuildIndustryWindow : public Window {
/** Update status of the fund and display-chain widgets. */
void SetButtons()
{
this->SetWidgetsDisabledState(!this->enabled[this->selected_index], DPIW_DISPLAY_WIDGET, DPIW_FUND_WIDGET, WIDGET_LIST_END);
this->SetWidgetDisabledState(DPIW_FUND_WIDGET, this->selected_type != INVALID_INDUSTRYTYPE && !this->enabled[this->selected_index]);
this->SetWidgetDisabledState(DPIW_DISPLAY_WIDGET, this->selected_type == INVALID_INDUSTRYTYPE && this->enabled[this->selected_index]);
}
public: