2022-02-26 06:19:38 +00:00
|
|
|
// Copyright 2022 Dolphin Emulator Project
|
|
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <map>
|
|
|
|
#include <string>
|
2024-01-31 17:05:15 +00:00
|
|
|
#include <string_view>
|
2022-02-26 06:19:38 +00:00
|
|
|
#include <vector>
|
|
|
|
|
|
|
|
#include "Common/CommonTypes.h"
|
|
|
|
|
|
|
|
struct GraphicsModConfig;
|
|
|
|
|
|
|
|
class GraphicsModGroupConfig
|
|
|
|
{
|
|
|
|
public:
|
2024-01-25 03:40:03 +00:00
|
|
|
explicit GraphicsModGroupConfig(std::string game_id);
|
2022-02-26 06:19:38 +00:00
|
|
|
~GraphicsModGroupConfig();
|
|
|
|
|
|
|
|
GraphicsModGroupConfig(const GraphicsModGroupConfig&);
|
2024-01-25 03:41:28 +00:00
|
|
|
GraphicsModGroupConfig(GraphicsModGroupConfig&&) noexcept;
|
2022-02-26 06:19:38 +00:00
|
|
|
|
|
|
|
GraphicsModGroupConfig& operator=(const GraphicsModGroupConfig&);
|
2024-01-25 03:41:28 +00:00
|
|
|
GraphicsModGroupConfig& operator=(GraphicsModGroupConfig&&) noexcept;
|
2022-02-26 06:19:38 +00:00
|
|
|
|
|
|
|
void Load();
|
|
|
|
void Save() const;
|
|
|
|
|
|
|
|
void SetChangeCount(u32 change_count);
|
|
|
|
u32 GetChangeCount() const;
|
|
|
|
|
|
|
|
const std::vector<GraphicsModConfig>& GetMods() const;
|
2022-07-23 15:14:26 +00:00
|
|
|
std::vector<GraphicsModConfig>& GetMods();
|
2022-02-26 06:19:38 +00:00
|
|
|
|
2024-01-31 17:05:15 +00:00
|
|
|
GraphicsModConfig* GetMod(std::string_view absolute_path) const;
|
2022-02-26 06:19:38 +00:00
|
|
|
|
|
|
|
const std::string& GetGameID() const;
|
|
|
|
|
|
|
|
private:
|
|
|
|
std::string GetPath() const;
|
|
|
|
std::string m_game_id;
|
|
|
|
std::vector<GraphicsModConfig> m_graphics_mods;
|
2024-01-31 17:05:15 +00:00
|
|
|
std::map<std::string, GraphicsModConfig*, std::less<>> m_path_to_graphics_mod;
|
2022-02-26 06:19:38 +00:00
|
|
|
u32 m_change_count = 0;
|
|
|
|
};
|