summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/VideoConfig.cpp
diff options
context:
space:
mode:
authormitaclaw <140017135+mitaclaw@users.noreply.github.com>2024-09-20 22:17:29 -0700
committermitaclaw <140017135+mitaclaw@users.noreply.github.com>2025-01-01 09:52:03 -0800
commit110d32729ecbe5b19df9b2cc76de630334410589 (patch)
tree0032af6f60d1b8575bc5bfcbefb8c3faa951d96f /Source/Core/VideoCommon/VideoConfig.cpp
parent6f10acea3fee4d08c4e52e66f862da45ad06d1ed (diff)
Simplify `std::find` with `Common::Contains`
In NandPaths.cpp, the `std::initializer_list<char>` of illegal characters has been turned into a `char[]` (similar to the one in GameList.cpp). The reverse iteration in ResourcePack.cpp seemed to provide no benefits, and doing without it it seemed to have no ill effects.
Diffstat (limited to 'Source/Core/VideoCommon/VideoConfig.cpp')
-rw-r--r--Source/Core/VideoCommon/VideoConfig.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/Core/VideoCommon/VideoConfig.cpp b/Source/Core/VideoCommon/VideoConfig.cpp
index 8ca1f4ec63..9c73608b22 100644
--- a/Source/Core/VideoCommon/VideoConfig.cpp
+++ b/Source/Core/VideoCommon/VideoConfig.cpp
@@ -7,6 +7,7 @@
#include "Common/CPUDetect.h"
#include "Common/CommonTypes.h"
+#include "Common/Contains.h"
#include "Common/StringUtil.h"
#include "Core/CPUThreadConfigCallback.h"
@@ -213,8 +214,7 @@ void VideoConfig::VerifyValidity()
if (iAdapter < 0 || iAdapter > ((int)backend_info.Adapters.size() - 1))
iAdapter = 0;
- if (std::find(backend_info.AAModes.begin(), backend_info.AAModes.end(), iMultisamples) ==
- backend_info.AAModes.end())
+ if (!Common::Contains(backend_info.AAModes, iMultisamples))
iMultisamples = 1;
if (stereo_mode != StereoMode::Off)