From adfa096230a242b2acf3c090f4d9d88b2df3d485 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Wed, 23 Sep 2015 05:00:51 -0400 Subject: [PATCH] Correct order of class initialization lists --- Source/Project64/N64 System/Mips/FlashRam.cpp | 2 +- .../N64 System/Mips/Memory Virtual Mem.cpp | 8 +++---- Source/Project64/N64 System/Mips/Sram.cpp | 4 ++-- .../N64 System/Mips/System Events.cpp | 4 ++-- Source/Project64/N64 System/N64 Class.cpp | 24 +++++++++---------- .../N64 System/Recompiler/Code Block.cpp | 4 ++-- .../N64 System/Recompiler/Code Section.cpp | 6 ++--- .../N64 System/Recompiler/Function Info.cpp | 2 +- .../Recompiler/Recompiler Class.cpp | 4 ++-- Source/Project64/Plugins/Audio Plugin.cpp | 6 ++--- .../Project64/Plugins/Controller Plugin.cpp | 4 ++-- Source/Project64/Plugins/Plugin Base.cpp | 16 ++++++------- Source/Project64/Plugins/Plugin Class.cpp | 6 ++--- Source/Project64/Plugins/RSP Plugin.cpp | 4 ++-- .../SettingType/SettingsType-Application.cpp | 16 ++++++------- .../User Interface/Notification Class.cpp | 6 ++--- .../User Interface/Rom Browser Class.cpp | 6 ++--- .../WTL Controls/ModifiedComboBox.h | 8 +++---- 18 files changed, 65 insertions(+), 65 deletions(-) diff --git a/Source/Project64/N64 System/Mips/FlashRam.cpp b/Source/Project64/N64 System/Mips/FlashRam.cpp index be14d04d5..6d4ba3a1f 100644 --- a/Source/Project64/N64 System/Mips/FlashRam.cpp +++ b/Source/Project64/N64 System/Mips/FlashRam.cpp @@ -11,9 +11,9 @@ #include "stdafx.h" CFlashram::CFlashram(bool ReadOnly): + m_FlashRamPointer(NULL), m_FlashFlag(FLASHRAM_MODE_NOPES), m_FlashStatus(0), - m_FlashRamPointer(NULL), m_FlashRAM_Offset(0), m_ReadOnly(ReadOnly), m_hFile(NULL) diff --git a/Source/Project64/N64 System/Mips/Memory Virtual Mem.cpp b/Source/Project64/N64 System/Mips/Memory Virtual Mem.cpp index 6245405a6..c21d5abca 100644 --- a/Source/Project64/N64 System/Mips/Memory Virtual Mem.cpp +++ b/Source/Project64/N64 System/Mips/Memory Virtual Mem.cpp @@ -16,14 +16,12 @@ BYTE * CMipsMemoryVM::m_Reserve1 = NULL; BYTE * CMipsMemoryVM::m_Reserve2 = NULL; CMipsMemoryVM::CMipsMemoryVM( CMipsMemory_CallBack * CallBack, bool SavesReadOnly ) : - + CPifRam(SavesReadOnly), CFlashram(SavesReadOnly), CSram(SavesReadOnly), CDMA(*this,*this), m_CBClass(CallBack), - m_TLB_ReadMap(NULL), - m_TLB_WriteMap(NULL), m_RomMapped(false), m_Rom(NULL), m_RomSize(0), @@ -32,7 +30,9 @@ CMipsMemoryVM::CMipsMemoryVM( CMipsMemory_CallBack * CallBack, bool SavesReadOnl m_HalfLine(0), m_HalfLineCheck(false), m_FieldSerration(0), - m_TempValue(0) + m_TempValue(0), + m_TLB_ReadMap(NULL), + m_TLB_WriteMap(NULL) { g_Settings->RegisterChangeCB(Game_RDRamSize,this,(CSettings::SettingChangedFunc)RdramChanged); m_RDRAM = NULL; diff --git a/Source/Project64/N64 System/Mips/Sram.cpp b/Source/Project64/N64 System/Mips/Sram.cpp index e23e832f0..689ed2338 100644 --- a/Source/Project64/N64 System/Mips/Sram.cpp +++ b/Source/Project64/N64 System/Mips/Sram.cpp @@ -11,8 +11,8 @@ #include "stdafx.h" CSram::CSram ( bool ReadOnly ) : - m_hFile(NULL), - m_ReadOnly(ReadOnly) + m_ReadOnly(ReadOnly), + m_hFile(NULL) { } diff --git a/Source/Project64/N64 System/Mips/System Events.cpp b/Source/Project64/N64 System/Mips/System Events.cpp index a4e7639b7..2bd74cb24 100644 --- a/Source/Project64/N64 System/Mips/System Events.cpp +++ b/Source/Project64/N64 System/Mips/System Events.cpp @@ -11,9 +11,9 @@ #include "stdafx.h" CSystemEvents::CSystemEvents(CN64System * System, CPlugins * Plugins) : - m_bDoSomething(false), m_System(System), - m_Plugins(Plugins) + m_Plugins(Plugins), + m_bDoSomething(false) { } diff --git a/Source/Project64/N64 System/N64 Class.cpp b/Source/Project64/N64 System/N64 Class.cpp index f2bdd8c0b..4b8e60eea 100644 --- a/Source/Project64/N64 System/N64 Class.cpp +++ b/Source/Project64/N64 System/N64 Class.cpp @@ -17,33 +17,33 @@ CN64System::CN64System ( CPlugins * Plugins, bool SavesReadOnly ) : CSystemEvents(this, Plugins), + m_Cheats(NULL), + m_EndEmulation(false), + m_SaveUsing((SAVE_CHIP_TYPE)g_Settings->LoadDword(Game_SaveChip)), + m_Plugins(Plugins), + m_SyncCPU(NULL), m_SyncPlugins(NULL), m_SyncWindow(NULL), - m_Reg(this,this), m_MMU_VM(this,SavesReadOnly), m_TLB(this), + m_Reg(this,this), m_FPS(g_Notify), - m_Plugins(Plugins), - m_Cheats(NULL), - m_SyncCPU(NULL), m_Recomp(NULL), m_InReset(false), - m_EndEmulation(false), - m_bCleanFrameBox(true), - m_bInitialized(false), m_NextTimer(0), m_SystemTimer(m_NextTimer), + m_bCleanFrameBox(true), + m_bInitialized(false), + m_RspBroke(true), m_DMAUsed(false), - m_CPU_Handle(NULL), - m_CPU_ThreadID(0), m_TestTimer(false), m_NextInstruction(0), m_JumpToLocation(0), m_TLBLoadAddress(0), m_TLBStoreAddress(0), - m_SaveUsing((SAVE_CHIP_TYPE)g_Settings->LoadDword(Game_SaveChip)), - m_RspBroke(true), - m_SyncCount(0) + m_SyncCount(0), + m_CPU_Handle(NULL), + m_CPU_ThreadID(0) { DWORD gameHertz = g_Settings->LoadDword(Game_ScreenHertz); if (gameHertz == 0) diff --git a/Source/Project64/N64 System/Recompiler/Code Block.cpp b/Source/Project64/N64 System/Recompiler/Code Block.cpp index a5eb42dd1..adcae84cd 100644 --- a/Source/Project64/N64 System/Recompiler/Code Block.cpp +++ b/Source/Project64/N64 System/Recompiler/Code Block.cpp @@ -17,8 +17,8 @@ CCodeBlock::CCodeBlock(DWORD VAddrEnter, BYTE * RecompPos) : m_VAddrFirst(VAddrEnter), m_VAddrLast(VAddrEnter), m_CompiledLocation(RecompPos), - m_Test(1), - m_EnterSection(NULL) + m_EnterSection(NULL), + m_Test(1) { CCodeSection * baseSection = new CCodeSection(this, VAddrEnter, 0, false); if (baseSection == NULL) diff --git a/Source/Project64/N64 System/Recompiler/Code Section.cpp b/Source/Project64/N64 System/Recompiler/Code Section.cpp index 2db6b2948..6da875477 100644 --- a/Source/Project64/N64 System/Recompiler/Code Section.cpp +++ b/Source/Project64/N64 System/Recompiler/Code Section.cpp @@ -88,17 +88,17 @@ static bool DelaySlotEffectsJump(DWORD JumpPC) { CCodeSection::CCodeSection( CCodeBlock * CodeBlock, DWORD EnterPC, DWORD ID, bool LinkAllowed) : m_BlockInfo(CodeBlock), + m_SectionID(ID), m_EnterPC(EnterPC), m_EndPC((DWORD)-1), - m_SectionID(ID), m_ContinueSection(NULL), m_JumpSection(NULL), + m_EndSection(false), m_LinkAllowed(LinkAllowed), - m_CompiledLocation(NULL), m_Test(0), m_Test2(0), + m_CompiledLocation(NULL), m_InLoop(false), - m_EndSection(false), m_DelaySlot(false) { CPU_Message(__FUNCTION__ ": ID %d EnterPC 0x%08X",ID,EnterPC); diff --git a/Source/Project64/N64 System/Recompiler/Function Info.cpp b/Source/Project64/N64 System/Recompiler/Function Info.cpp index b273d1e3e..38b694ff1 100644 --- a/Source/Project64/N64 System/Recompiler/Function Info.cpp +++ b/Source/Project64/N64 System/Recompiler/Function Info.cpp @@ -14,8 +14,8 @@ CCompiledFunc::CCompiledFunc( const CCodeBlock & CodeBlock ) : m_EnterPC(CodeBlock.VAddrEnter()), m_MinPC(CodeBlock.VAddrFirst()), m_MaxPC(CodeBlock.VAddrLast()), - m_Function((Func)CodeBlock.CompiledLocation()), m_Hash(CodeBlock.Hash()), + m_Function((Func)CodeBlock.CompiledLocation()), m_Next(NULL) { m_MemContents[0] = CodeBlock.MemContents(0); diff --git a/Source/Project64/N64 System/Recompiler/Recompiler Class.cpp b/Source/Project64/N64 System/Recompiler/Recompiler Class.cpp index cdfb5e5de..56fee2bbb 100644 --- a/Source/Project64/N64 System/Recompiler/Recompiler Class.cpp +++ b/Source/Project64/N64 System/Recompiler/Recompiler Class.cpp @@ -13,8 +13,8 @@ CRecompiler::CRecompiler(CRegisters & Registers, CProfiling & Profile, bool & EndEmulation ) : m_Registers(Registers), m_Profile(Profile), - PROGRAM_COUNTER(Registers.m_PROGRAM_COUNTER), - m_EndEmulation(EndEmulation) + m_EndEmulation(EndEmulation), + PROGRAM_COUNTER(Registers.m_PROGRAM_COUNTER) { if (g_MMU != NULL) { diff --git a/Source/Project64/Plugins/Audio Plugin.cpp b/Source/Project64/Plugins/Audio Plugin.cpp index d2d1651d0..8d7c6e52e 100644 --- a/Source/Project64/Plugins/Audio Plugin.cpp +++ b/Source/Project64/Plugins/Audio Plugin.cpp @@ -11,12 +11,12 @@ #include "stdafx.h" CAudioPlugin::CAudioPlugin() : - m_hAudioThread(NULL), - AiDacrateChanged(NULL), AiLenChanged(NULL), AiReadLength(NULL), ProcessAList(NULL), - AiUpdate(NULL) + m_hAudioThread(NULL), + AiUpdate(NULL), + AiDacrateChanged(NULL) { } diff --git a/Source/Project64/Plugins/Controller Plugin.cpp b/Source/Project64/Plugins/Controller Plugin.cpp index 8369ce6ca..b935a02d9 100644 --- a/Source/Project64/Plugins/Controller Plugin.cpp +++ b/Source/Project64/Plugins/Controller Plugin.cpp @@ -11,13 +11,13 @@ #include "stdafx.h" CControl_Plugin::CControl_Plugin(void) : - m_AllocatedControllers(false), WM_KeyDown(NULL), WM_KeyUp(NULL), RumbleCommand(NULL), GetKeys(NULL), ReadController(NULL), - ControllerCommand(NULL) + ControllerCommand(NULL), + m_AllocatedControllers(false) { memset(&m_PluginControllers, 0, sizeof(m_PluginControllers)); memset(&m_Controllers, 0, sizeof(m_Controllers)); diff --git a/Source/Project64/Plugins/Plugin Base.cpp b/Source/Project64/Plugins/Plugin Base.cpp index 0e1f0f8d5..49a73dce0 100644 --- a/Source/Project64/Plugins/Plugin Base.cpp +++ b/Source/Project64/Plugins/Plugin Base.cpp @@ -11,18 +11,18 @@ #include "stdafx.h" CPlugin::CPlugin() : - m_hDll(NULL), - m_Initialized(false), - m_RomOpen(false), - RomOpen(NULL), - RomClosed(NULL), - CloseDLL(NULL), - PluginOpened(NULL), DllAbout(NULL), DllConfig(NULL), + CloseDLL(NULL), + RomOpen(NULL), + RomClosed(NULL), + PluginOpened(NULL), SetSettingInfo(NULL), SetSettingInfo2(NULL), - SetSettingInfo3(NULL) + SetSettingInfo3(NULL), + m_hDll(NULL), + m_Initialized(false), + m_RomOpen(false) { memset(&m_PluginInfo, 0, sizeof(m_PluginInfo)); } diff --git a/Source/Project64/Plugins/Plugin Class.cpp b/Source/Project64/Plugins/Plugin Class.cpp index cbfa7886a..45ef88b18 100644 --- a/Source/Project64/Plugins/Plugin Class.cpp +++ b/Source/Project64/Plugins/Plugin Class.cpp @@ -11,9 +11,9 @@ #include "stdafx.h" CPlugins::CPlugins (const stdstr & PluginDir): - m_PluginDir(PluginDir), - m_Gfx(NULL), m_Audio(NULL), m_RSP(NULL), m_Control(NULL), - m_RenderWindow(NULL), m_DummyWindow(NULL) + m_RenderWindow(NULL), m_DummyWindow(NULL), + m_PluginDir(PluginDir), m_Gfx(NULL), m_Audio(NULL), + m_RSP(NULL), m_Control(NULL) { CreatePlugins(); g_Settings->RegisterChangeCB(Plugin_RSP_Current,this,(CSettings::SettingChangedFunc)PluginChanged); diff --git a/Source/Project64/Plugins/RSP Plugin.cpp b/Source/Project64/Plugins/RSP Plugin.cpp index e660a8cd0..5239068db 100644 --- a/Source/Project64/Plugins/RSP Plugin.cpp +++ b/Source/Project64/Plugins/RSP Plugin.cpp @@ -15,9 +15,9 @@ void DummyFunc1(BOOL /*a*/) {} CRSP_Plugin::CRSP_Plugin(void) : DoRspCycles(NULL), EnableDebugging(NULL), + m_CycleCount(0), GetDebugInfo(NULL), - InitiateDebugger(NULL), - m_CycleCount(0) + InitiateDebugger(NULL) { memset(&m_RSPDebug, 0, sizeof(m_RSPDebug)); } diff --git a/Source/Project64/Settings/SettingType/SettingsType-Application.cpp b/Source/Project64/Settings/SettingType/SettingsType-Application.cpp index 08fad99ce..0115aaa84 100644 --- a/Source/Project64/Settings/SettingType/SettingsType-Application.cpp +++ b/Source/Project64/Settings/SettingType/SettingsType-Application.cpp @@ -15,41 +15,41 @@ bool CSettingTypeApplication::m_UseRegistry = false; CIniFile * CSettingTypeApplication::m_SettingsIniFile = NULL; CSettingTypeApplication::CSettingTypeApplication(LPCSTR Section, LPCSTR Name, DWORD DefaultValue ) : - m_Section(FixSectionName(Section)), - m_KeyName(Name), m_DefaultStr(""), m_DefaultValue(DefaultValue), m_DefaultSetting(Default_Constant), + m_Section(FixSectionName(Section)), + m_KeyName(Name), m_KeyNameIdex(m_KeyName) { } CSettingTypeApplication::CSettingTypeApplication(LPCSTR Section, LPCSTR Name, bool DefaultValue ) : - m_Section(FixSectionName(Section)), - m_KeyName(Name), m_DefaultStr(""), m_DefaultValue(DefaultValue), m_DefaultSetting(Default_Constant), + m_Section(FixSectionName(Section)), + m_KeyName(Name), m_KeyNameIdex(m_KeyName) { } CSettingTypeApplication::CSettingTypeApplication(LPCSTR Section, LPCSTR Name, LPCSTR DefaultValue ) : - m_Section(FixSectionName(Section)), - m_KeyName(Name), m_DefaultStr(DefaultValue), m_DefaultValue(0), m_DefaultSetting(Default_Constant), + m_Section(FixSectionName(Section)), + m_KeyName(Name), m_KeyNameIdex(m_KeyName) { } CSettingTypeApplication::CSettingTypeApplication(LPCSTR Section, LPCSTR Name, SettingID DefaultSetting ) : - m_Section(FixSectionName(Section)), - m_KeyName(Name), m_DefaultStr(""), m_DefaultValue(0), m_DefaultSetting(DefaultSetting), + m_Section(FixSectionName(Section)), + m_KeyName(Name), m_KeyNameIdex(m_KeyName) { } diff --git a/Source/Project64/User Interface/Notification Class.cpp b/Source/Project64/User Interface/Notification Class.cpp index f07c89216..7769d536c 100644 --- a/Source/Project64/User Interface/Notification Class.cpp +++ b/Source/Project64/User Interface/Notification Class.cpp @@ -7,10 +7,10 @@ CNotification & Notify ( void ) return g_Notify; } -CNotification::CNotification ( ) : - m_NextMsg(0), +CNotification::CNotification() : + m_hWnd(NULL), m_gfxPlugin(NULL), - m_hWnd(NULL) + m_NextMsg(0) { _tzset(); } diff --git a/Source/Project64/User Interface/Rom Browser Class.cpp b/Source/Project64/User Interface/Rom Browser Class.cpp index d15f6a240..748f6c1e4 100644 --- a/Source/Project64/User Interface/Rom Browser Class.cpp +++ b/Source/Project64/User Interface/Rom Browser Class.cpp @@ -6,14 +6,14 @@ CRomBrowser::CRomBrowser (HWND & MainWindow, HWND & StatusWindow ) : m_MainWindow(MainWindow), m_StatusWindow(StatusWindow), + m_ShowingRomBrowser(false), m_RefreshThread(NULL), m_RomIniFile(NULL), m_NotesIniFile(NULL), m_ExtIniFile(NULL), m_ZipIniFile(NULL), - m_WatchThreadID(0), - m_ShowingRomBrowser(false), - m_AllowSelectionLastRom(true) + m_AllowSelectionLastRom(true), + m_WatchThreadID(0) { if (g_Settings) { diff --git a/Source/Project64/User Interface/WTL Controls/ModifiedComboBox.h b/Source/Project64/User Interface/WTL Controls/ModifiedComboBox.h index 843b64d6f..e6da4a608 100644 --- a/Source/Project64/User Interface/WTL Controls/ModifiedComboBox.h +++ b/Source/Project64/User Interface/WTL Controls/ModifiedComboBox.h @@ -19,14 +19,14 @@ class CModifiedComboBoxT : public: // Constructors CModifiedComboBoxT(TParam defaultValue, HWND hWnd = NULL, bool AllwaysSelected = true) : - CComboBox(hWnd), - m_defaultValue(defaultValue), - m_AllwaysSelected(AllwaysSelected), + CComboBox(hWnd), m_Changed(false), m_Reset(false), + m_defaultValue(defaultValue), m_BoldFont(NULL), m_OriginalFont(NULL), - m_TextField(NULL) + m_TextField(NULL), + m_AllwaysSelected(AllwaysSelected) { }