diff options
author | Narr the Reg <juangerman-13@hotmail.com> | 2024-01-31 17:25:28 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-31 17:25:28 +0100 |
commit | 7cc7d027f74b5bffc0b3f8f3a6c3110999c7cc4c (patch) | |
tree | 24b2ed412f2683c8460839778ea7761d052bc38f /src/core/hle/service/am/frontend/applet_mii_edit.cpp | |
parent | Merge pull request #12858 from liamwhite/non-blocking (diff) | |
parent | am: push storage from error applet with non-zero size (diff) | |
download | yuzu-7cc7d027f74b5bffc0b3f8f3a6c3110999c7cc4c.tar yuzu-7cc7d027f74b5bffc0b3f8f3a6c3110999c7cc4c.tar.gz yuzu-7cc7d027f74b5bffc0b3f8f3a6c3110999c7cc4c.tar.bz2 yuzu-7cc7d027f74b5bffc0b3f8f3a6c3110999c7cc4c.tar.lz yuzu-7cc7d027f74b5bffc0b3f8f3a6c3110999c7cc4c.tar.xz yuzu-7cc7d027f74b5bffc0b3f8f3a6c3110999c7cc4c.tar.zst yuzu-7cc7d027f74b5bffc0b3f8f3a6c3110999c7cc4c.zip |
Diffstat (limited to '')
-rw-r--r-- | src/core/hle/service/am/frontend/applet_mii_edit.cpp (renamed from src/core/hle/service/am/applets/applet_mii_edit.cpp) | 27 |
1 files changed, 12 insertions, 15 deletions
diff --git a/src/core/hle/service/am/applets/applet_mii_edit.cpp b/src/core/hle/service/am/frontend/applet_mii_edit.cpp index e83e931c5..e3d19fb3d 100644 --- a/src/core/hle/service/am/applets/applet_mii_edit.cpp +++ b/src/core/hle/service/am/frontend/applet_mii_edit.cpp @@ -6,16 +6,17 @@ #include "core/core.h" #include "core/frontend/applets/mii_edit.h" #include "core/hle/service/am/am.h" -#include "core/hle/service/am/applets/applet_mii_edit.h" +#include "core/hle/service/am/frontend/applet_mii_edit.h" +#include "core/hle/service/am/storage.h" #include "core/hle/service/mii/mii.h" #include "core/hle/service/mii/mii_manager.h" #include "core/hle/service/sm/sm.h" -namespace Service::AM::Applets { +namespace Service::AM::Frontend { -MiiEdit::MiiEdit(Core::System& system_, LibraryAppletMode applet_mode_, - const Core::Frontend::MiiEditApplet& frontend_) - : Applet{system_, applet_mode_}, frontend{frontend_}, system{system_} {} +MiiEdit::MiiEdit(Core::System& system_, std::shared_ptr<Applet> applet_, + LibraryAppletMode applet_mode_, const Core::Frontend::MiiEditApplet& frontend_) + : FrontendApplet{system_, applet_, applet_mode_}, frontend{frontend_} {} MiiEdit::~MiiEdit() = default; @@ -24,7 +25,7 @@ void MiiEdit::Initialize() { // Instead, it is initialized by an AppletInput storage with size 0x100 bytes. // Do NOT call Applet::Initialize() here. - const auto storage = broker.PopNormalDataToApplet(); + const std::shared_ptr<IStorage> storage = PopInData(); ASSERT(storage != nullptr); const auto applet_input_data = storage->GetData(); @@ -66,10 +67,6 @@ void MiiEdit::Initialize() { manager->Initialize(metadata); } -bool MiiEdit::TransactionComplete() const { - return is_complete; -} - Result MiiEdit::GetStatus() const { return ResultSuccess; } @@ -152,8 +149,8 @@ void MiiEdit::MiiEditOutput(MiiEditResult result, s32 index) { is_complete = true; - broker.PushNormalDataFromApplet(std::make_shared<IStorage>(system, std::move(out_data))); - broker.SignalStateChanged(); + PushOutData(std::make_shared<IStorage>(system, std::move(out_data))); + Exit(); } void MiiEdit::MiiEditOutputForCharInfoEditing(MiiEditResult result, @@ -168,8 +165,8 @@ void MiiEdit::MiiEditOutputForCharInfoEditing(MiiEditResult result, is_complete = true; - broker.PushNormalDataFromApplet(std::make_shared<IStorage>(system, std::move(out_data))); - broker.SignalStateChanged(); + PushOutData(std::make_shared<IStorage>(system, std::move(out_data))); + Exit(); } Result MiiEdit::RequestExit() { @@ -177,4 +174,4 @@ Result MiiEdit::RequestExit() { R_SUCCEED(); } -} // namespace Service::AM::Applets +} // namespace Service::AM::Frontend |