File diff r26193:4bc7915a2156 → r26194:f7347205838e
src/fios_gui.cpp
Show inline comments
 
@@ -51,12 +51,15 @@ void LoadCheckData::Clear()
 
	this->error = INVALID_STRING_ID;
 
	free(this->error_data);
 
	this->error_data = nullptr;
 

	
 
	this->map_size_x = this->map_size_y = 256; // Default for old savegames which do not store mapsize.
 
	this->current_date = 0;
 
	this->save_version = SL_MIN_VERSION;
 
	this->save_ext_type = PSXT_NONE;
 
	this->save_version_label = "";
 
	this->settings = {};
 

	
 
	for (auto &pair : this->companies) {
 
		delete pair.second;
 
	}
 
	companies.clear();
 
@@ -468,12 +471,25 @@ public:
 
				if (this->selected == nullptr) break;
 

	
 
				uint y = r.top + FONT_HEIGHT_NORMAL * 2 + WD_PAR_VSEP_NORMAL + WD_FRAMERECT_TOP + WD_FRAMERECT_BOTTOM;
 
				uint y_max = r.bottom - FONT_HEIGHT_NORMAL - WD_FRAMERECT_BOTTOM;
 

	
 
				if (y > y_max) break;
 
				if (_load_check_data.checkable) {
 
					SetDParam(0, _load_check_data.save_version);
 
					SetDParamStr(1, _load_check_data.save_ext_type == PSXT_EXTENDED ? "X" : _load_check_data.save_ext_type == PSXT_MODIFIED ? "M"  : "");
 
					DrawString(r.left + WD_FRAMERECT_LEFT, r.right - WD_FRAMERECT_RIGHT, y, STR_SAVELOAD_VERSION_WITH_EXTENSION);
 
					y += FONT_HEIGHT_NORMAL;
 
					if (_load_check_data.save_version_label.length() > 0)
 
					{
 
						SetDParamStr(0, _load_check_data.save_version_label.c_str());
 
						DrawString(r.left + WD_FRAMERECT_LEFT, r.right - WD_FRAMERECT_RIGHT, y, STR_SAVELOAD_VERSION_LABEL);
 
						y += FONT_HEIGHT_NORMAL;
 
					}
 
					y += FONT_HEIGHT_NORMAL;
 
				}
 
				if (!_load_check_data.checkable) {
 
					/* Old savegame, no information available */
 
					DrawString(r.left + WD_FRAMERECT_LEFT, r.right - WD_FRAMERECT_RIGHT, y, STR_SAVELOAD_DETAIL_NOT_AVAILABLE);
 
					y += FONT_HEIGHT_NORMAL;
 
				} else if (_load_check_data.error != INVALID_STRING_ID) {
 
					/* Incompatible / broken savegame */