From 7b8610f4ea4f90074c79c750c9a27fc90d9dc99f Mon Sep 17 00:00:00 2001 From: Dentomologist Date: Sun, 3 Nov 2024 11:33:51 -0800 Subject: [PATCH] VideoBackendBase: Clarify function name Rename GetDefaultBackendName to GetDefaultBackendConfigName to distinguish it from the display name. --- .../main/java/org/dolphinemu/dolphinemu/NativeLibrary.java | 2 +- .../dolphinemu/features/settings/model/StringSetting.kt | 2 +- Source/Android/jni/MainAndroid.cpp | 5 +++-- Source/Core/Core/Config/MainSettings.cpp | 2 +- Source/Core/VideoCommon/VideoBackendBase.cpp | 2 +- Source/Core/VideoCommon/VideoBackendBase.h | 2 +- 6 files changed, 8 insertions(+), 7 deletions(-) diff --git a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/NativeLibrary.java b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/NativeLibrary.java index 63d40d5a91..8a024499af 100644 --- a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/NativeLibrary.java +++ b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/NativeLibrary.java @@ -302,7 +302,7 @@ public final class NativeLibrary public static native int DefaultCPUCore(); - public static native String GetDefaultGraphicsBackendName(); + public static native String GetDefaultGraphicsBackendConfigName(); public static native int GetMaxLogLevel(); diff --git a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.kt b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.kt index f959764564..b150c845e1 100644 --- a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.kt +++ b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.kt @@ -45,7 +45,7 @@ enum class StringSetting( Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "GFXBackend", - NativeLibrary.GetDefaultGraphicsBackendName() + NativeLibrary.GetDefaultGraphicsBackendConfigName() ), MAIN_DUMP_PATH(Settings.FILE_DOLPHIN, Settings.SECTION_INI_GENERAL, "DumpPath", ""), MAIN_LOAD_PATH(Settings.FILE_DOLPHIN, Settings.SECTION_INI_GENERAL, "LoadPath", ""), diff --git a/Source/Android/jni/MainAndroid.cpp b/Source/Android/jni/MainAndroid.cpp index 40aada1195..bc6205e190 100644 --- a/Source/Android/jni/MainAndroid.cpp +++ b/Source/Android/jni/MainAndroid.cpp @@ -408,9 +408,10 @@ JNIEXPORT jint JNICALL Java_org_dolphinemu_dolphinemu_NativeLibrary_DefaultCPUCo } JNIEXPORT jstring JNICALL -Java_org_dolphinemu_dolphinemu_NativeLibrary_GetDefaultGraphicsBackendName(JNIEnv* env, jclass) +Java_org_dolphinemu_dolphinemu_NativeLibrary_GetDefaultGraphicsBackendConfigName(JNIEnv* env, + jclass) { - return ToJString(env, VideoBackendBase::GetDefaultBackendName()); + return ToJString(env, VideoBackendBase::GetDefaultBackendConfigName()); } JNIEXPORT jint JNICALL Java_org_dolphinemu_dolphinemu_NativeLibrary_GetMaxLogLevel(JNIEnv*, jclass) diff --git a/Source/Core/Core/Config/MainSettings.cpp b/Source/Core/Core/Config/MainSettings.cpp index 7f4e9989b7..c9cd0333a9 100644 --- a/Source/Core/Core/Config/MainSettings.cpp +++ b/Source/Core/Core/Config/MainSettings.cpp @@ -212,7 +212,7 @@ const Info MAIN_RAM_OVERRIDE_ENABLE{{System::Main, "Core", "RAMOverrideEna const Info MAIN_MEM1_SIZE{{System::Main, "Core", "MEM1Size"}, Memory::MEM1_SIZE_RETAIL}; const Info MAIN_MEM2_SIZE{{System::Main, "Core", "MEM2Size"}, Memory::MEM2_SIZE_RETAIL}; const Info MAIN_GFX_BACKEND{{System::Main, "Core", "GFXBackend"}, - VideoBackendBase::GetDefaultBackendName()}; + VideoBackendBase::GetDefaultBackendConfigName()}; const Info MAIN_HSP_DEVICE{{System::Main, "Core", "HSPDevice"}, HSP::HSPDeviceType::None}; const Info MAIN_ARAM_EXPANSION_SIZE{{System::Main, "Core", "ARAMExpansionSize"}, 0x400000}; diff --git a/Source/Core/VideoCommon/VideoBackendBase.cpp b/Source/Core/VideoCommon/VideoBackendBase.cpp index faf7ac19c6..d545311fd7 100644 --- a/Source/Core/VideoCommon/VideoBackendBase.cpp +++ b/Source/Core/VideoCommon/VideoBackendBase.cpp @@ -222,7 +222,7 @@ static VideoBackendBase* GetDefaultVideoBackend() return backends.front().get(); } -std::string VideoBackendBase::GetDefaultBackendName() +std::string VideoBackendBase::GetDefaultBackendConfigName() { auto* default_backend = GetDefaultVideoBackend(); return default_backend ? default_backend->GetName() : ""; diff --git a/Source/Core/VideoCommon/VideoBackendBase.h b/Source/Core/VideoCommon/VideoBackendBase.h index 5d9ab020d2..76771ae49c 100644 --- a/Source/Core/VideoCommon/VideoBackendBase.h +++ b/Source/Core/VideoCommon/VideoBackendBase.h @@ -64,7 +64,7 @@ public: u32 Video_GetQueryResult(PerfQueryType type); u16 Video_GetBoundingBox(int index); - static std::string GetDefaultBackendName(); + static std::string GetDefaultBackendConfigName(); static const std::vector>& GetAvailableBackends(); static void ActivateBackend(const std::string& name);