Files
yuzu/src/core/frontend/applets/profile_select.cpp

22 lines
759 B
C++
Raw Normal View History

2020-12-28 15:15:37 +00:00
// Copyright 2018 yuzu emulator team
// Licensed under GPLv2 or any later version
// Refer to the license.txt file included.
2021-04-15 04:05:28 +02:00
#include "common/settings.h"
2020-12-28 15:15:37 +00:00
#include "core/frontend/applets/profile_select.h"
#include "core/hle/service/acc/profile_manager.h"
namespace Core::Frontend {
ProfileSelectApplet::~ProfileSelectApplet() = default;
void DefaultProfileSelectApplet::SelectProfile(
std::function<void(std::optional<Common::UUID>)> callback) const {
Service::Account::ProfileManager manager;
2021-09-24 15:00:03 +02:00
callback(manager.GetUser(Settings::values.current_user.GetValue())
.value_or(Common::UUID{Common::INVALID_UUID}));
2020-12-28 15:15:37 +00:00
LOG_INFO(Service_ACC, "called, selecting current user instead of prompting...");
}
} // namespace Core::Frontend