mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2026-08-24 19:36:01 -05:00
c++23: Replace Common::ToUnderlying with std::to_underlying
Requires at least GCC 11, Clang 13, MSVC 19.30 (VS2022 17.0), or AppleClang 13.1.6 (XCode 13.3).
This commit is contained in:
@@ -3,6 +3,8 @@
|
||||
|
||||
#include "DolphinQt/Config/Graphics/EnhancementsWidget.h"
|
||||
|
||||
#include <utility>
|
||||
|
||||
#include <QGridLayout>
|
||||
#include <QGroupBox>
|
||||
#include <QLabel>
|
||||
@@ -10,7 +12,6 @@
|
||||
#include <QVBoxLayout>
|
||||
|
||||
#include "Common/CommonTypes.h"
|
||||
#include "Common/EnumUtils.h"
|
||||
|
||||
#include "Core/Config/GraphicsSettings.h"
|
||||
|
||||
@@ -47,14 +48,14 @@ EnhancementsWidget::EnhancementsWidget(GraphicsPane* gfx_pane)
|
||||
});
|
||||
}
|
||||
|
||||
constexpr int ANISO_1x = Common::ToUnderlying(AnisotropicFilteringMode::Force1x);
|
||||
constexpr int ANISO_2X = Common::ToUnderlying(AnisotropicFilteringMode::Force2x);
|
||||
constexpr int ANISO_4X = Common::ToUnderlying(AnisotropicFilteringMode::Force4x);
|
||||
constexpr int ANISO_8X = Common::ToUnderlying(AnisotropicFilteringMode::Force8x);
|
||||
constexpr int ANISO_16X = Common::ToUnderlying(AnisotropicFilteringMode::Force16x);
|
||||
constexpr int FILTERING_DEFAULT = Common::ToUnderlying(TextureFilteringMode::Default);
|
||||
constexpr int FILTERING_NEAREST = Common::ToUnderlying(TextureFilteringMode::Nearest);
|
||||
constexpr int FILTERING_LINEAR = Common::ToUnderlying(TextureFilteringMode::Linear);
|
||||
constexpr int ANISO_1x = std::to_underlying(AnisotropicFilteringMode::Force1x);
|
||||
constexpr int ANISO_2X = std::to_underlying(AnisotropicFilteringMode::Force2x);
|
||||
constexpr int ANISO_4X = std::to_underlying(AnisotropicFilteringMode::Force4x);
|
||||
constexpr int ANISO_8X = std::to_underlying(AnisotropicFilteringMode::Force8x);
|
||||
constexpr int ANISO_16X = std::to_underlying(AnisotropicFilteringMode::Force16x);
|
||||
constexpr int FILTERING_DEFAULT = std::to_underlying(TextureFilteringMode::Default);
|
||||
constexpr int FILTERING_NEAREST = std::to_underlying(TextureFilteringMode::Nearest);
|
||||
constexpr int FILTERING_LINEAR = std::to_underlying(TextureFilteringMode::Linear);
|
||||
|
||||
void EnhancementsWidget::CreateWidgets()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user