File diff r11367:a13b3a453e57 → r11368:058349c3a02c
src/town_gui.cpp
Show inline comments
 
@@ -202,18 +202,18 @@ public:
 
	virtual void OnHundredthTick()
 
	{
 
		this->SetDirty();
 
	}
 
};
 

	
 
static const WindowDesc _town_authority_desc = {
 
static const WindowDesc _town_authority_desc(
 
	WDP_AUTO, WDP_AUTO, 317, 222, 317, 222,
 
	WC_TOWN_AUTHORITY, WC_NONE,
 
	WDF_STD_TOOLTIPS | WDF_STD_BTN | WDF_DEF_WIDGET | WDF_UNCLICK_BUTTONS,
 
	_town_authority_widgets,
 
};
 
	_town_authority_widgets
 
);
 

	
 
static void ShowTownAuthorityWindow(uint town)
 
{
 
	AllocateWindowDescFront<TownAuthorityWindow>(&_town_authority_desc, town);
 
}
 

	
 
@@ -429,18 +429,18 @@ static const Widget _town_view_widgets[]
 
{ WWT_PUSHTXTBTN,   RESIZE_NONE,  COLOUR_BROWN,   172,   247,     0,    13, STR_0130_RENAME,          STR_200C_CHANGE_TOWN_NAME},
 
{ WWT_PUSHTXTBTN,   RESIZE_NONE,  COLOUR_BROWN,    86,   171,   138,   149, STR_023C_EXPAND,          STR_023B_INCREASE_SIZE_OF_TOWN},
 
{ WWT_PUSHTXTBTN,   RESIZE_NONE,  COLOUR_BROWN,   172,   259,   138,   149, STR_0290_DELETE,          STR_0291_DELETE_THIS_TOWN_COMPLETELY},
 
{   WIDGETS_END},
 
};
 

	
 
static const WindowDesc _town_view_desc = {
 
static const WindowDesc _town_view_desc(
 
	WDP_AUTO, WDP_AUTO, 260, TownViewWindow::TVW_HEIGHT_NORMAL, 260, TownViewWindow::TVW_HEIGHT_NORMAL,
 
	WC_TOWN_VIEW, WC_NONE,
 
	WDF_STD_TOOLTIPS | WDF_STD_BTN | WDF_DEF_WIDGET | WDF_UNCLICK_BUTTONS | WDF_STICKY_BUTTON,
 
	_town_view_widgets,
 
};
 
	_town_view_widgets
 
);
 

	
 
void ShowTownViewWindow(TownID town)
 
{
 
	AllocateWindowDescFront<TownViewWindow>(&_town_view_desc, town);
 
}
 

	
 
@@ -646,18 +646,18 @@ const Town *TownDirectoryWindow::last_to
 
/* Available town directory sorting functions */
 
GUITownList::SortFunction * const TownDirectoryWindow::sorter_funcs[] = {
 
	&TownNameSorter,
 
	&TownPopulationSorter,
 
};
 

	
 
static const WindowDesc _town_directory_desc = {
 
static const WindowDesc _town_directory_desc(
 
	WDP_AUTO, WDP_AUTO, 208, 202, 208, 202,
 
	WC_TOWN_DIRECTORY, WC_NONE,
 
	WDF_STD_TOOLTIPS | WDF_STD_BTN | WDF_DEF_WIDGET | WDF_UNCLICK_BUTTONS | WDF_STICKY_BUTTON | WDF_RESIZABLE,
 
	_town_directory_widgets,
 
};
 
	_town_directory_widgets
 
);
 

	
 
void ShowTownDirectory()
 
{
 
	if (BringWindowToFrontById(WC_TOWN_DIRECTORY, 0)) return;
 
	new TownDirectoryWindow(&_town_directory_desc);
 
}
 
@@ -835,18 +835,18 @@ public:
 
};
 

	
 
TownSize FoundTownWindow::town_size = TS_MEDIUM; // select medium-sized towns per default;
 
bool FoundTownWindow::city;
 
TownLayout FoundTownWindow::town_layout;
 

	
 
static const WindowDesc _found_town_desc = {
 
static const WindowDesc _found_town_desc(
 
	WDP_AUTO, WDP_AUTO, 160, 162, 160, 162,
 
	WC_FOUND_TOWN, WC_NONE,
 
	WDF_STD_TOOLTIPS | WDF_STD_BTN | WDF_DEF_WIDGET | WDF_STICKY_BUTTON | WDF_CONSTRUCTION,
 
	_found_town_widgets,
 
};
 
	_found_town_widgets
 
);
 

	
 
void ShowBuildTownWindow()
 
{
 
	if (_game_mode != GM_EDITOR && !IsValidCompanyID(_local_company)) return;
 
	AllocateWindowDescFront<FoundTownWindow>(&_found_town_desc, 0);
 
}