Helper for scanning for files with GRF as extension. More...
Public Member Functions | |
| bool | AddFile (const char *filename, size_t basepath_length, const char *tar_filename) |
| Add a file with the given filename. | |
Static Public Member Functions | |
| static uint | DoScan () |
| Do the scan for GRFs. | |
Private Attributes | |
| uint | next_update |
| The next (realtime tick) we do update the screen. | |
| uint | num_scanned |
| The number of GRFs we have scanned. | |
Helper for scanning for files with GRF as extension.
Definition at line 574 of file newgrf_config.cpp.
| bool GRFFileScanner::AddFile | ( | const char * | filename, | |
| size_t | basepath_length, | |||
| const char * | tar_filename | |||
| ) | [virtual] |
Add a file with the given filename.
| filename | the full path to the file to read | |
| basepath_length | amount of characters to chop of before to get a filename relative to the search path. | |
| tar_filename | the name of the tar file the file is read from. |
Implements FileScanner.
Definition at line 597 of file newgrf_config.cpp.
References _modal_progress_paint_mutex, _modal_progress_work_mutex, _realtime_tick, ThreadMutex::BeginCritical(), ThreadMutex::EndCritical(), GRFConfig::filename, FillGRFDetails(), GetGRFStringFromGRFText(), GRFConfig::GetName(), GRFIdentifier::grfid, GRFConfig::ident, GRFIdentifier::md5sum, GRFConfig::name, GRFConfig::next, next_update, num_scanned, GRFTextWrapper::text, and UpdateNewGRFScanStatus().
| static uint GRFFileScanner::DoScan | ( | ) | [inline, static] |
Do the scan for GRFs.
Definition at line 586 of file newgrf_config.cpp.
References _settings_client, ClientSettings::gui, GUISettings::last_newgrf_count, NEWGRF_DIR, num_scanned, and FileScanner::Scan().
Referenced by DoScanNewGRFFiles().
1.7.1