movie.cpp/movie.h: Fix compiling issues for old GCC 4.2, which doesn't allow for variable initialization in C++ class declarations. (Regression from commit e83ec89.)

This commit is contained in:
rogerman 2018-10-22 11:38:06 -07:00
parent 94ddf1a467
commit 68174fb31f
2 changed files with 39 additions and 22 deletions

View File

@ -208,6 +208,23 @@ MovieData::MovieData(bool fromCurrentSettings)
, binaryFlag(false) , binaryFlag(false)
, rtcStart(FCEUI_MovieGetRTCDefault()) , rtcStart(FCEUI_MovieGetRTCDefault())
{ {
savestate = false;
useExtBios = -1;
swiFromBios = -1;
useExtFirmware = -1;
bootFromFirmware = -1;
firmNickname = "";
firmMessage = "";
firmFavColour = -1;
firmBirthMonth = -1;
firmBirthDay = -1;
firmLanguage = -1;
advancedTiming = -1;
jitBlockSize = -1;
installValueMap["version"] = &MovieData::installVersion; installValueMap["version"] = &MovieData::installVersion;
installValueMap["emuVersion"] = &MovieData::installEmuVersion; installValueMap["emuVersion"] = &MovieData::installEmuVersion;
installValueMap["rerecordCount"] = &MovieData::installRerecordCount; installValueMap["rerecordCount"] = &MovieData::installRerecordCount;
@ -904,8 +921,8 @@ static void FCEUMOV_AddCommand(int cmd)
} }
//little endian 4-byte cookies //little endian 4-byte cookies
static const int kMOVI = 0x49564F4D; static const u32 kMOVI = 0x49564F4D;
static const int kNOMO = 0x4F4D4F4E; static const u32 kNOMO = 0x4F4D4F4E;
void mov_savestate(EMUFILE &fp) void mov_savestate(EMUFILE &fp)
{ {

View File

@ -149,7 +149,7 @@ public:
u32 romChecksum; u32 romChecksum;
std::string romSerial; std::string romSerial;
std::string romFilename; std::string romFilename;
bool savestate = false; bool savestate;
std::vector<u8> sram; std::vector<u8> sram;
std::vector<MovieRecord> records; std::vector<MovieRecord> records;
std::vector<std::wstring> comments; std::vector<std::wstring> comments;
@ -162,20 +162,20 @@ public:
//was the frame data stored in binary? //was the frame data stored in binary?
bool binaryFlag; bool binaryFlag;
int useExtBios = -1; int useExtBios;
int swiFromBios = -1; int swiFromBios;
int useExtFirmware = -1; int useExtFirmware;
int bootFromFirmware = -1; int bootFromFirmware;
std::string firmNickname = ""; std::string firmNickname;
std::string firmMessage = ""; std::string firmMessage;
int firmFavColour = -1; int firmFavColour;
int firmBirthMonth = -1; int firmBirthMonth;
int firmBirthDay = -1; int firmBirthDay;
int firmLanguage = -1; int firmLanguage;
int advancedTiming = -1; int advancedTiming;
int jitBlockSize = -1; int jitBlockSize;
int getNumRecords() { return records.size(); } int getNumRecords() { return records.size(); }