forked from ShuriZma/suyu
core: Keep instance of APM Controller
This commit is contained in:
parent
e52306ca60
commit
e2ad3e1fb0
|
@ -25,6 +25,7 @@
|
||||||
#include "core/hle/kernel/scheduler.h"
|
#include "core/hle/kernel/scheduler.h"
|
||||||
#include "core/hle/kernel/thread.h"
|
#include "core/hle/kernel/thread.h"
|
||||||
#include "core/hle/service/am/applets/applets.h"
|
#include "core/hle/service/am/applets/applets.h"
|
||||||
|
#include "core/hle/service/apm/controller.h"
|
||||||
#include "core/hle/service/glue/manager.h"
|
#include "core/hle/service/glue/manager.h"
|
||||||
#include "core/hle/service/service.h"
|
#include "core/hle/service/service.h"
|
||||||
#include "core/hle/service/sm/sm.h"
|
#include "core/hle/service/sm/sm.h"
|
||||||
|
@ -304,6 +305,9 @@ struct System::Impl {
|
||||||
/// Frontend applets
|
/// Frontend applets
|
||||||
Service::AM::Applets::AppletManager applet_manager;
|
Service::AM::Applets::AppletManager applet_manager;
|
||||||
|
|
||||||
|
/// APM (Performance) services
|
||||||
|
Service::APM::Controller apm_controller{core_timing};
|
||||||
|
|
||||||
/// Glue services
|
/// Glue services
|
||||||
Service::Glue::ARPManager arp_manager;
|
Service::Glue::ARPManager arp_manager;
|
||||||
|
|
||||||
|
@ -566,6 +570,14 @@ const Service::Glue::ARPManager& System::GetARPManager() const {
|
||||||
return impl->arp_manager;
|
return impl->arp_manager;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Service::APM::Controller& System::GetAPMController() {
|
||||||
|
return impl->apm_controller;
|
||||||
|
}
|
||||||
|
|
||||||
|
const Service::APM::Controller& System::GetAPMController() const {
|
||||||
|
return impl->apm_controller;
|
||||||
|
}
|
||||||
|
|
||||||
System::ResultStatus System::Init(Frontend::EmuWindow& emu_window) {
|
System::ResultStatus System::Init(Frontend::EmuWindow& emu_window) {
|
||||||
return impl->Init(*this, emu_window);
|
return impl->Init(*this, emu_window);
|
||||||
}
|
}
|
||||||
|
|
|
@ -43,6 +43,10 @@ struct AppletFrontendSet;
|
||||||
class AppletManager;
|
class AppletManager;
|
||||||
} // namespace AM::Applets
|
} // namespace AM::Applets
|
||||||
|
|
||||||
|
namespace APM {
|
||||||
|
class Controller;
|
||||||
|
}
|
||||||
|
|
||||||
namespace Glue {
|
namespace Glue {
|
||||||
class ARPManager;
|
class ARPManager;
|
||||||
}
|
}
|
||||||
|
@ -296,6 +300,10 @@ public:
|
||||||
|
|
||||||
const Service::Glue::ARPManager& GetARPManager() const;
|
const Service::Glue::ARPManager& GetARPManager() const;
|
||||||
|
|
||||||
|
Service::APM::Controller& GetAPMController();
|
||||||
|
|
||||||
|
const Service::APM::Controller& GetAPMController() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
System();
|
System();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue