mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-24 14:49:42 -06:00
Config: Include SYSCONF in base layer
Settings that come from the SYSCONF are now included in Dolphin's config system as part of the base layer. They are handled in a special way compared to other settings to make sure they are only loaded from and saved to the SYSCONF (to avoid different, possibly contradicting sources of truth).
This commit is contained in:
@ -101,8 +101,7 @@ void ClearCurrentRunLayer()
|
||||
static const std::map<System, std::string> system_to_name = {
|
||||
{System::Main, "Dolphin"}, {System::GCPad, "GCPad"}, {System::WiiPad, "Wiimote"},
|
||||
{System::GCKeyboard, "GCKeyboard"}, {System::GFX, "Graphics"}, {System::Logger, "Logger"},
|
||||
{System::Debugger, "Debugger"}, {System::UI, "UI"},
|
||||
};
|
||||
{System::Debugger, "Debugger"}, {System::UI, "UI"}, {System::SYSCONF, "SYSCONF"}};
|
||||
|
||||
const std::string& GetSystemName(System system)
|
||||
{
|
||||
|
@ -23,6 +23,7 @@ enum class LayerType
|
||||
enum class System
|
||||
{
|
||||
Main,
|
||||
SYSCONF,
|
||||
GCPad,
|
||||
WiiPad,
|
||||
GCKeyboard,
|
||||
|
@ -14,7 +14,6 @@
|
||||
#include "Common/FileUtil.h"
|
||||
#include "Common/Logging/Log.h"
|
||||
#include "Common/Swap.h"
|
||||
#include "Core/Movie.h"
|
||||
|
||||
constexpr size_t SYSCONF_SIZE = 0x4000;
|
||||
|
||||
@ -61,8 +60,6 @@ void SysConf::Load()
|
||||
WARN_LOG(CORE, "No valid SYSCONF detected. Creating a new one.");
|
||||
InsertDefaultEntries();
|
||||
}
|
||||
|
||||
ApplySettingsFromMovie();
|
||||
}
|
||||
|
||||
bool SysConf::LoadFromFile(const std::string& file_name)
|
||||
@ -257,17 +254,6 @@ void SysConf::RemoveEntry(const std::string& key)
|
||||
m_entries.end());
|
||||
}
|
||||
|
||||
// Apply Wii settings from normal SYSCONF on Movie recording/playback
|
||||
void SysConf::ApplySettingsFromMovie()
|
||||
{
|
||||
if (!Movie::IsMovieActive())
|
||||
return;
|
||||
|
||||
SetData<u8>("IPL.LNG", Entry::Type::Byte, Movie::GetLanguage());
|
||||
SetData<u8>("IPL.E60", Entry::Type::Byte, Movie::IsPAL60());
|
||||
SetData<u8>("IPL.PGS", Entry::Type::Byte, Movie::IsProgressive());
|
||||
}
|
||||
|
||||
void SysConf::InsertDefaultEntries()
|
||||
{
|
||||
AddEntry({Entry::Type::BigArray, "BT.DINF", std::vector<u8>(0x460 + 1)});
|
||||
|
@ -84,7 +84,6 @@ public:
|
||||
}
|
||||
|
||||
private:
|
||||
void ApplySettingsFromMovie();
|
||||
void InsertDefaultEntries();
|
||||
bool LoadFromFile(const std::string& file_name);
|
||||
|
||||
|
Reference in New Issue
Block a user