SDL: Simplify implementation of createLogFile()

This commit is contained in:
Cameron Cawley 2019-08-04 21:45:17 +01:00 committed by Filippos Karapetis
parent d10c69d0d1
commit 8b8fb6d3a4
18 changed files with 86 additions and 114 deletions

View file

@ -93,6 +93,16 @@ protected:
bool _initedSDLnet;
#endif
/**
* The path of the currently open log file, if any.
*
* @note This is currently a string and not an FSNode for simplicity;
* e.g. we don't need to include fs.h here, and currently the
* only use of this value is to use it to open the log file in an
* editor; for that, we need it only as a string anyway.
*/
Common::String _logFilePath;
/**
* Mixer manager that configures and setups SDL for
* the wrapped Audio::Mixer, the true mixer.
@ -122,7 +132,8 @@ protected:
virtual AudioCDManager *createAudioCDManager();
// Logging
virtual Common::WriteStream *createLogFile() { return 0; }
virtual Common::String getDefaultLogFileName() { return Common::String(); }
virtual Common::WriteStream *createLogFile();
Backends::Log::Log *_logger;
#ifdef USE_OPENGL