From 09d48710671ac5272d028f548a9e12134d8af8d3 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Tue, 14 Mar 2017 19:08:41 -0400 Subject: [PATCH] GCMemcard: Move memcard source files to their own directory GCMemcard.h has quite a bit of different classes implemented within it that could likely be split up into other files to make it a little easier to read. However, they should be moved into their own folder first so that they don't clutter up the base HW directory. --- Source/Core/Core/CMakeLists.txt | 6 +++--- Source/Core/Core/Core.vcxproj | 12 ++++++------ Source/Core/Core/Core.vcxproj.filters | 12 ++++++------ Source/Core/Core/HW/EXI/EXI_DeviceMemoryCard.cpp | 6 +++--- Source/Core/Core/HW/{ => GCMemcard}/GCMemcard.cpp | 2 +- Source/Core/Core/HW/{ => GCMemcard}/GCMemcard.h | 0 .../Core/HW/{ => GCMemcard}/GCMemcardDirectory.cpp | 3 ++- .../Core/HW/{ => GCMemcard}/GCMemcardDirectory.h | 2 +- Source/Core/Core/HW/{ => GCMemcard}/GCMemcardRaw.cpp | 5 +++-- Source/Core/Core/HW/{ => GCMemcard}/GCMemcardRaw.h | 2 +- Source/Core/DolphinWX/Config/GameCubeConfigPane.cpp | 2 +- Source/Core/DolphinWX/MemcardManager.cpp | 2 +- 12 files changed, 28 insertions(+), 26 deletions(-) rename Source/Core/Core/HW/{ => GCMemcard}/GCMemcard.cpp (99%) rename Source/Core/Core/HW/{ => GCMemcard}/GCMemcard.h (100%) rename Source/Core/Core/HW/{ => GCMemcard}/GCMemcardDirectory.cpp (99%) rename Source/Core/Core/HW/{ => GCMemcard}/GCMemcardDirectory.h (97%) rename Source/Core/Core/HW/{ => GCMemcard}/GCMemcardRaw.cpp (98%) rename Source/Core/Core/HW/{ => GCMemcard}/GCMemcardRaw.h (95%) diff --git a/Source/Core/Core/CMakeLists.txt b/Source/Core/Core/CMakeLists.txt index 7f737dc1a3..0c8ed8946a 100644 --- a/Source/Core/Core/CMakeLists.txt +++ b/Source/Core/Core/CMakeLists.txt @@ -104,9 +104,9 @@ set(SRCS HW/EXI/EXI_DeviceMic.cpp HW/GCKeyboard.cpp HW/GCKeyboardEmu.cpp - HW/GCMemcard.cpp - HW/GCMemcardDirectory.cpp - HW/GCMemcardRaw.cpp + HW/GCMemcard/GCMemcard.cpp + HW/GCMemcard/GCMemcardDirectory.cpp + HW/GCMemcard/GCMemcardRaw.cpp HW/GCPad.cpp HW/GCPadEmu.cpp HW/GPFifo.cpp diff --git a/Source/Core/Core/Core.vcxproj b/Source/Core/Core/Core.vcxproj index ae8fd022ec..549bc38c35 100644 --- a/Source/Core/Core/Core.vcxproj +++ b/Source/Core/Core/Core.vcxproj @@ -130,9 +130,9 @@ - - - + + + @@ -380,9 +380,9 @@ - - - + + + diff --git a/Source/Core/Core/Core.vcxproj.filters b/Source/Core/Core/Core.vcxproj.filters index 4a5ecc2a3d..1d5792cc33 100644 --- a/Source/Core/Core/Core.vcxproj.filters +++ b/Source/Core/Core/Core.vcxproj.filters @@ -440,13 +440,13 @@ HW %28Flipper/Hollywood%29\EXI - Expansion Interface - + HW %28Flipper/Hollywood%29\GCMemcard - + HW %28Flipper/Hollywood%29\GCMemcard - + HW %28Flipper/Hollywood%29\GCMemcard @@ -1092,13 +1092,13 @@ HW %28Flipper/Hollywood%29\EXI - Expansion Interface - + HW %28Flipper/Hollywood%29\GCMemcard - + HW %28Flipper/Hollywood%29\GCMemcard - + HW %28Flipper/Hollywood%29\GCMemcard diff --git a/Source/Core/Core/HW/EXI/EXI_DeviceMemoryCard.cpp b/Source/Core/Core/HW/EXI/EXI_DeviceMemoryCard.cpp index 69654a4cbf..2b8fc22465 100644 --- a/Source/Core/Core/HW/EXI/EXI_DeviceMemoryCard.cpp +++ b/Source/Core/Core/HW/EXI/EXI_DeviceMemoryCard.cpp @@ -22,9 +22,9 @@ #include "Core/HW/EXI/EXI.h" #include "Core/HW/EXI/EXI_Channel.h" #include "Core/HW/EXI/EXI_Device.h" -#include "Core/HW/GCMemcard.h" -#include "Core/HW/GCMemcardDirectory.h" -#include "Core/HW/GCMemcardRaw.h" +#include "Core/HW/GCMemcard/GCMemcard.h" +#include "Core/HW/GCMemcard/GCMemcardDirectory.h" +#include "Core/HW/GCMemcard/GCMemcardRaw.h" #include "Core/HW/Memmap.h" #include "Core/HW/Sram.h" #include "Core/HW/SystemTimers.h" diff --git a/Source/Core/Core/HW/GCMemcard.cpp b/Source/Core/Core/HW/GCMemcard/GCMemcard.cpp similarity index 99% rename from Source/Core/Core/HW/GCMemcard.cpp rename to Source/Core/Core/HW/GCMemcard/GCMemcard.cpp index c0af034eac..bc3c93f177 100644 --- a/Source/Core/Core/HW/GCMemcard.cpp +++ b/Source/Core/Core/HW/GCMemcard/GCMemcard.cpp @@ -2,7 +2,7 @@ // Licensed under GPLv2+ // Refer to the license.txt file included. -#include "Core/HW/GCMemcard.h" +#include "Core/HW/GCMemcard/GCMemcard.h" #include #include diff --git a/Source/Core/Core/HW/GCMemcard.h b/Source/Core/Core/HW/GCMemcard/GCMemcard.h similarity index 100% rename from Source/Core/Core/HW/GCMemcard.h rename to Source/Core/Core/HW/GCMemcard/GCMemcard.h diff --git a/Source/Core/Core/HW/GCMemcardDirectory.cpp b/Source/Core/Core/HW/GCMemcard/GCMemcardDirectory.cpp similarity index 99% rename from Source/Core/Core/HW/GCMemcardDirectory.cpp rename to Source/Core/Core/HW/GCMemcard/GCMemcardDirectory.cpp index 489b5a4dce..a80181427a 100644 --- a/Source/Core/Core/HW/GCMemcardDirectory.cpp +++ b/Source/Core/Core/HW/GCMemcard/GCMemcardDirectory.cpp @@ -2,6 +2,8 @@ // Licensed under GPLv2+ // Refer to the license.txt file included. +#include "Core/HW/GCMemcard/GCMemcardDirectory.h" + #include #include #include @@ -18,7 +20,6 @@ #include "Common/Thread.h" #include "Core/ConfigManager.h" #include "Core/Core.h" -#include "Core/HW/GCMemcardDirectory.h" #include "DiscIO/Volume.h" const int NO_INDEX = -1; diff --git a/Source/Core/Core/HW/GCMemcardDirectory.h b/Source/Core/Core/HW/GCMemcard/GCMemcardDirectory.h similarity index 97% rename from Source/Core/Core/HW/GCMemcardDirectory.h rename to Source/Core/Core/HW/GCMemcard/GCMemcardDirectory.h index 8a1dcba1c5..22fed4acad 100644 --- a/Source/Core/Core/HW/GCMemcardDirectory.h +++ b/Source/Core/Core/HW/GCMemcard/GCMemcardDirectory.h @@ -12,7 +12,7 @@ #include "Common/Event.h" #include "Common/NonCopyable.h" -#include "Core/HW/GCMemcard.h" +#include "Core/HW/GCMemcard/GCMemcard.h" #include "DiscIO/Enums.h" // Uncomment this to write the system data of the memorycard from directory to disc diff --git a/Source/Core/Core/HW/GCMemcardRaw.cpp b/Source/Core/Core/HW/GCMemcard/GCMemcardRaw.cpp similarity index 98% rename from Source/Core/Core/HW/GCMemcardRaw.cpp rename to Source/Core/Core/HW/GCMemcard/GCMemcardRaw.cpp index 344964b7cb..f14eb2e03e 100644 --- a/Source/Core/Core/HW/GCMemcardRaw.cpp +++ b/Source/Core/Core/HW/GCMemcard/GCMemcardRaw.cpp @@ -2,6 +2,8 @@ // Licensed under GPLv2+ // Refer to the license.txt file included. +#include "Core/HW/GCMemcard/GCMemcardRaw.h" + #include #include #include @@ -15,8 +17,7 @@ #include "Common/Thread.h" #include "Core/ConfigManager.h" #include "Core/Core.h" -#include "Core/HW/GCMemcard.h" -#include "Core/HW/GCMemcardRaw.h" +#include "Core/HW/GCMemcard/GCMemcard.h" #define SIZE_TO_Mb (1024 * 8 * 16) #define MC_HDR_SIZE 0xA000 diff --git a/Source/Core/Core/HW/GCMemcardRaw.h b/Source/Core/Core/HW/GCMemcard/GCMemcardRaw.h similarity index 95% rename from Source/Core/Core/HW/GCMemcardRaw.h rename to Source/Core/Core/HW/GCMemcard/GCMemcardRaw.h index fdd582658d..744685c478 100644 --- a/Source/Core/Core/HW/GCMemcardRaw.h +++ b/Source/Core/Core/HW/GCMemcard/GCMemcardRaw.h @@ -10,7 +10,7 @@ #include #include "Common/Event.h" #include "Common/Flag.h" -#include "Core/HW/GCMemcard.h" +#include "Core/HW/GCMemcard/GCMemcard.h" class PointerWrap; diff --git a/Source/Core/DolphinWX/Config/GameCubeConfigPane.cpp b/Source/Core/DolphinWX/Config/GameCubeConfigPane.cpp index cfd580934c..e9e4e86600 100644 --- a/Source/Core/DolphinWX/Config/GameCubeConfigPane.cpp +++ b/Source/Core/DolphinWX/Config/GameCubeConfigPane.cpp @@ -23,7 +23,7 @@ #include "Core/ConfigManager.h" #include "Core/Core.h" #include "Core/HW/EXI/EXI.h" -#include "Core/HW/GCMemcard.h" +#include "Core/HW/GCMemcard/GCMemcard.h" #include "Core/HW/GCPad.h" #include "Core/NetPlayProto.h" #include "DolphinWX/Config/ConfigMain.h" diff --git a/Source/Core/DolphinWX/MemcardManager.cpp b/Source/Core/DolphinWX/MemcardManager.cpp index 3ac86e860c..9609772ab3 100644 --- a/Source/Core/DolphinWX/MemcardManager.cpp +++ b/Source/Core/DolphinWX/MemcardManager.cpp @@ -29,7 +29,7 @@ #include "Common/Logging/Log.h" #include "Common/MsgHandler.h" #include "Common/StringUtil.h" -#include "Core/HW/GCMemcard.h" +#include "Core/HW/GCMemcard/GCMemcard.h" #include "DolphinWX/WxUtils.h" #define FIRSTPAGE 0