Logging: Log full file names of opened GRFs

This commit is contained in:
Jonathan G Rennison
2019-12-11 20:34:04 +00:00
parent fe9b024f1a
commit 6ada7c3c7f
5 changed files with 33 additions and 18 deletions

View File

@@ -156,6 +156,7 @@ struct GRFConfig : ZeroedMemoryAllocator {
GRFIdentifier ident; ///< grfid and md5sum to uniquely identify newgrfs
uint8 original_md5sum[16]; ///< MD5 checksum of original file if only a 'compatible' file was loaded
char *filename; ///< Filename - either with or without full path
char *full_filename; ///< NOSAVE: Full filename
GRFTextWrapper *name; ///< NOSAVE: GRF name (Action 0x08)
GRFTextWrapper *info; ///< NOSAVE: GRF info (author, copyright, ...) (Action 0x08)
GRFTextWrapper *url; ///< NOSAVE: URL belonging to this GRF.
@@ -182,6 +183,11 @@ struct GRFConfig : ZeroedMemoryAllocator {
const char *GetDescription() const;
const char *GetURL() const;
const char *GetDisplayPath() const
{
return this->full_filename ? this->full_filename : this->filename;
}
void SetParameterDefaults();
void SetSuitablePalette();
void FinalizeParameterInfo();