From dfb9fa0144ca79e596f6f2b1bc960b1a44745aa6 Mon Sep 17 00:00:00 2001 From: Liam Date: Sun, 31 Dec 2023 09:40:32 -0500 Subject: am: re-namespace frontend applets to frontend directory --- src/core/core.h | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'src/core/core.h') diff --git a/src/core/core.h b/src/core/core.h index d8862e9ce..800e69501 100644 --- a/src/core/core.h +++ b/src/core/core.h @@ -50,10 +50,10 @@ namespace Account { class ProfileManager; } // namespace Account -namespace AM::Applets { -struct AppletFrontendSet; -class AppletManager; -} // namespace AM::Applets +namespace AM::Frontend { +struct FrontendAppletSet; +class FrontendAppletHolder; +} // namespace AM::Frontend namespace APM { class Controller; @@ -344,11 +344,12 @@ public: const std::array& build_id, u64 main_region_begin, u64 main_region_size); - void SetAppletFrontendSet(Service::AM::Applets::AppletFrontendSet&& set); + void SetFrontendAppletSet(Service::AM::Frontend::FrontendAppletSet&& set); void SetDefaultAppletFrontendSet(); - [[nodiscard]] Service::AM::Applets::AppletManager& GetAppletManager(); - [[nodiscard]] const Service::AM::Applets::AppletManager& GetAppletManager() const; + [[nodiscard]] Service::AM::Frontend::FrontendAppletHolder& GetFrontendAppletHolder(); + [[nodiscard]] const Service::AM::Frontend::FrontendAppletHolder& GetFrontendAppletHolder() + const; void SetContentProvider(std::unique_ptr provider); -- cgit v1.2.3 From 3155f4e96d10904f4a207e465f20fb4b25043f5c Mon Sep 17 00:00:00 2001 From: Liam Date: Tue, 2 Jan 2024 18:26:53 -0500 Subject: am: retrieve main applet creation info from frontend --- src/core/core.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src/core/core.h') diff --git a/src/core/core.h b/src/core/core.h index 800e69501..97e2d4b50 100644 --- a/src/core/core.h +++ b/src/core/core.h @@ -50,6 +50,11 @@ namespace Account { class ProfileManager; } // namespace Account +namespace AM { +struct FrontendAppletParameters; +class AppletManager; +} // namespace AM + namespace AM::Frontend { struct FrontendAppletSet; class FrontendAppletHolder; @@ -203,8 +208,8 @@ public: * @returns SystemResultStatus code, indicating if the operation succeeded. */ [[nodiscard]] SystemResultStatus Load(Frontend::EmuWindow& emu_window, - const std::string& filepath, u64 program_id = 0, - std::size_t program_index = 0); + const std::string& filepath, + Service::AM::FrontendAppletParameters& params); /** * Indicates if the emulated system is powered on (all subsystems initialized and able to run an -- cgit v1.2.3 From 182137a9a4b09c8188d2cbffa312550c5dc83641 Mon Sep 17 00:00:00 2001 From: Liam Date: Tue, 2 Jan 2024 18:29:03 -0500 Subject: am: migrate global state to per-applet state structure --- src/core/core.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/core/core.h') diff --git a/src/core/core.h b/src/core/core.h index 97e2d4b50..90826bd3a 100644 --- a/src/core/core.h +++ b/src/core/core.h @@ -350,12 +350,13 @@ public: u64 main_region_size); void SetFrontendAppletSet(Service::AM::Frontend::FrontendAppletSet&& set); - void SetDefaultAppletFrontendSet(); [[nodiscard]] Service::AM::Frontend::FrontendAppletHolder& GetFrontendAppletHolder(); [[nodiscard]] const Service::AM::Frontend::FrontendAppletHolder& GetFrontendAppletHolder() const; + [[nodiscard]] Service::AM::AppletManager& GetAppletManager(); + void SetContentProvider(std::unique_ptr provider); [[nodiscard]] FileSys::ContentProvider& GetContentProvider(); -- cgit v1.2.3