Core: pass down Core::System reference to all services (#4272)
* Core: pass down Core::System reference to all services This has to be done at once due to unified interface used by HLE/LLE switcher * apt: eliminate Core::System::GetInstance * gpu_gsp: eliminate Core::System::GetInstance in service * hid: eliminate Core::System::GetInstance * nwm: eliminate Core::System::GetInstance * err_f: eliminate Core::System::GetInstance
This commit is contained in:
parent
008242c5f3
commit
b163502744
77 changed files with 329 additions and 111 deletions
|
@ -3,6 +3,7 @@
|
|||
// Refer to the license.txt file included.
|
||||
|
||||
#include <memory>
|
||||
#include "core/core.h"
|
||||
#include "core/hle/service/ir/ir.h"
|
||||
#include "core/hle/service/ir/ir_rst.h"
|
||||
#include "core/hle/service/ir/ir_u.h"
|
||||
|
@ -22,7 +23,8 @@ void ReloadInputDevices() {
|
|||
ir_rst->ReloadInputDevices();
|
||||
}
|
||||
|
||||
void InstallInterfaces(SM::ServiceManager& service_manager) {
|
||||
void InstallInterfaces(Core::System& system) {
|
||||
auto& service_manager = system.ServiceManager();
|
||||
std::make_shared<IR_U>()->InstallAsService(service_manager);
|
||||
|
||||
auto ir_user = std::make_shared<IR_USER>();
|
||||
|
|
|
@ -4,6 +4,10 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
namespace Core {
|
||||
class System;
|
||||
}
|
||||
|
||||
namespace SM {
|
||||
class ServiceManager;
|
||||
}
|
||||
|
@ -13,6 +17,6 @@ namespace Service::IR {
|
|||
/// Reload input devices. Used when input configuration changed
|
||||
void ReloadInputDevices();
|
||||
|
||||
void InstallInterfaces(SM::ServiceManager& service_manager);
|
||||
void InstallInterfaces(Core::System& system);
|
||||
|
||||
} // namespace Service::IR
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue