mirror of
https://github.com/yuzu-mirror/yuzu.git
synced 2024-11-08 05:49:59 +00:00
99ceb03a1c
This formats all copyright comments according to SPDX formatting guidelines. Additionally, this resolves the remaining GPLv2 only licensed files by relicensing them to GPLv2.0-or-later.
37 lines
938 B
C++
37 lines
938 B
C++
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
#pragma once
|
|
|
|
#include <string>
|
|
#include <unordered_map>
|
|
|
|
namespace Core {
|
|
class System;
|
|
}
|
|
|
|
class Config;
|
|
|
|
class InputProfiles {
|
|
|
|
public:
|
|
explicit InputProfiles(Core::System& system_);
|
|
virtual ~InputProfiles();
|
|
|
|
std::vector<std::string> GetInputProfileNames();
|
|
|
|
static bool IsProfileNameValid(std::string_view profile_name);
|
|
|
|
bool CreateProfile(const std::string& profile_name, std::size_t player_index);
|
|
bool DeleteProfile(const std::string& profile_name);
|
|
bool LoadProfile(const std::string& profile_name, std::size_t player_index);
|
|
bool SaveProfile(const std::string& profile_name, std::size_t player_index);
|
|
|
|
private:
|
|
bool ProfileExistsInMap(const std::string& profile_name) const;
|
|
|
|
std::unordered_map<std::string, std::unique_ptr<Config>> map_profiles;
|
|
|
|
Core::System& system;
|
|
};
|