diff options
| author | 2023-09-21 21:46:38 -0600 | |
|---|---|---|
| committer | 2023-09-23 20:14:37 -0600 | |
| commit | 6e1b113c896815ae1b347ce772af201e3ab3c524 (patch) | |
| tree | 6e1bc50115ec634a0c4f105b10e9d685bf44329d /src | |
| parent | service: am: Implement stuff needed for Mii Edit (diff) | |
| download | yuzu-6e1b113c896815ae1b347ce772af201e3ab3c524.tar.gz yuzu-6e1b113c896815ae1b347ce772af201e3ab3c524.tar.xz yuzu-6e1b113c896815ae1b347ce772af201e3ab3c524.zip | |
service: am: Stub to exit applet cleanly
Diffstat (limited to 'src')
| -rw-r--r-- | src/core/hle/service/am/am.cpp | 29 | ||||
| -rw-r--r-- | src/core/hle/service/am/am.h | 5 |
2 files changed, 31 insertions, 3 deletions
diff --git a/src/core/hle/service/am/am.cpp b/src/core/hle/service/am/am.cpp index 7c705651a..e9bd04842 100644 --- a/src/core/hle/service/am/am.cpp +++ b/src/core/hle/service/am/am.cpp | |||
| @@ -191,7 +191,7 @@ IDisplayController::IDisplayController(Core::System& system_) | |||
| 191 | {5, nullptr, "GetLastForegroundCaptureImageEx"}, | 191 | {5, nullptr, "GetLastForegroundCaptureImageEx"}, |
| 192 | {6, nullptr, "GetLastApplicationCaptureImageEx"}, | 192 | {6, nullptr, "GetLastApplicationCaptureImageEx"}, |
| 193 | {7, nullptr, "GetCallerAppletCaptureImageEx"}, | 193 | {7, nullptr, "GetCallerAppletCaptureImageEx"}, |
| 194 | {8, nullptr, "TakeScreenShotOfOwnLayer"}, | 194 | {8, &IDisplayController::TakeScreenShotOfOwnLayer, "TakeScreenShotOfOwnLayer"}, |
| 195 | {9, nullptr, "CopyBetweenCaptureBuffers"}, | 195 | {9, nullptr, "CopyBetweenCaptureBuffers"}, |
| 196 | {10, nullptr, "AcquireLastApplicationCaptureBuffer"}, | 196 | {10, nullptr, "AcquireLastApplicationCaptureBuffer"}, |
| 197 | {11, nullptr, "ReleaseLastApplicationCaptureBuffer"}, | 197 | {11, nullptr, "ReleaseLastApplicationCaptureBuffer"}, |
| @@ -219,6 +219,13 @@ IDisplayController::IDisplayController(Core::System& system_) | |||
| 219 | 219 | ||
| 220 | IDisplayController::~IDisplayController() = default; | 220 | IDisplayController::~IDisplayController() = default; |
| 221 | 221 | ||
| 222 | void IDisplayController::TakeScreenShotOfOwnLayer(HLERequestContext& ctx) { | ||
| 223 | LOG_WARNING(Service_AM, "(STUBBED) called"); | ||
| 224 | |||
| 225 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 226 | rb.Push(ResultSuccess); | ||
| 227 | } | ||
| 228 | |||
| 222 | IDebugFunctions::IDebugFunctions(Core::System& system_) | 229 | IDebugFunctions::IDebugFunctions(Core::System& system_) |
| 223 | : ServiceFramework{system_, "IDebugFunctions"} { | 230 | : ServiceFramework{system_, "IDebugFunctions"} { |
| 224 | // clang-format off | 231 | // clang-format off |
| @@ -1340,12 +1347,12 @@ ILibraryAppletSelfAccessor::ILibraryAppletSelfAccessor(Core::System& system_) | |||
| 1340 | // clang-format off | 1347 | // clang-format off |
| 1341 | static const FunctionInfo functions[] = { | 1348 | static const FunctionInfo functions[] = { |
| 1342 | {0, &ILibraryAppletSelfAccessor::PopInData, "PopInData"}, | 1349 | {0, &ILibraryAppletSelfAccessor::PopInData, "PopInData"}, |
| 1343 | {1, nullptr, "PushOutData"}, | 1350 | {1, &ILibraryAppletSelfAccessor::PushOutData, "PushOutData"}, |
| 1344 | {2, nullptr, "PopInteractiveInData"}, | 1351 | {2, nullptr, "PopInteractiveInData"}, |
| 1345 | {3, nullptr, "PushInteractiveOutData"}, | 1352 | {3, nullptr, "PushInteractiveOutData"}, |
| 1346 | {5, nullptr, "GetPopInDataEvent"}, | 1353 | {5, nullptr, "GetPopInDataEvent"}, |
| 1347 | {6, nullptr, "GetPopInteractiveInDataEvent"}, | 1354 | {6, nullptr, "GetPopInteractiveInDataEvent"}, |
| 1348 | {10, nullptr, "ExitProcessAndReturn"}, | 1355 | {10, &ILibraryAppletSelfAccessor::ExitProcessAndReturn, "ExitProcessAndReturn"}, |
| 1349 | {11, &ILibraryAppletSelfAccessor::GetLibraryAppletInfo, "GetLibraryAppletInfo"}, | 1356 | {11, &ILibraryAppletSelfAccessor::GetLibraryAppletInfo, "GetLibraryAppletInfo"}, |
| 1350 | {12, nullptr, "GetMainAppletIdentityInfo"}, | 1357 | {12, nullptr, "GetMainAppletIdentityInfo"}, |
| 1351 | {13, nullptr, "CanUseApplicationCore"}, | 1358 | {13, nullptr, "CanUseApplicationCore"}, |
| @@ -1399,6 +1406,22 @@ void ILibraryAppletSelfAccessor::PopInData(HLERequestContext& ctx) { | |||
| 1399 | rb.PushIpcInterface<IStorage>(system, std::move(data)); | 1406 | rb.PushIpcInterface<IStorage>(system, std::move(data)); |
| 1400 | } | 1407 | } |
| 1401 | 1408 | ||
| 1409 | void ILibraryAppletSelfAccessor::PushOutData(HLERequestContext& ctx) { | ||
| 1410 | LOG_WARNING(Service_AM, "(STUBBED) called"); | ||
| 1411 | |||
| 1412 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 1413 | rb.Push(ResultSuccess); | ||
| 1414 | } | ||
| 1415 | |||
| 1416 | void ILibraryAppletSelfAccessor::ExitProcessAndReturn(HLERequestContext& ctx) { | ||
| 1417 | LOG_WARNING(Service_AM, "(STUBBED) called"); | ||
| 1418 | |||
| 1419 | system.Exit(); | ||
| 1420 | |||
| 1421 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 1422 | rb.Push(ResultSuccess); | ||
| 1423 | } | ||
| 1424 | |||
| 1402 | void ILibraryAppletSelfAccessor::GetLibraryAppletInfo(HLERequestContext& ctx) { | 1425 | void ILibraryAppletSelfAccessor::GetLibraryAppletInfo(HLERequestContext& ctx) { |
| 1403 | struct LibraryAppletInfo { | 1426 | struct LibraryAppletInfo { |
| 1404 | Applets::AppletId applet_id; | 1427 | Applets::AppletId applet_id; |
diff --git a/src/core/hle/service/am/am.h b/src/core/hle/service/am/am.h index 3d5eae44e..5b97eb5e3 100644 --- a/src/core/hle/service/am/am.h +++ b/src/core/hle/service/am/am.h | |||
| @@ -120,6 +120,9 @@ class IDisplayController final : public ServiceFramework<IDisplayController> { | |||
| 120 | public: | 120 | public: |
| 121 | explicit IDisplayController(Core::System& system_); | 121 | explicit IDisplayController(Core::System& system_); |
| 122 | ~IDisplayController() override; | 122 | ~IDisplayController() override; |
| 123 | |||
| 124 | private: | ||
| 125 | void TakeScreenShotOfOwnLayer(HLERequestContext& ctx); | ||
| 123 | }; | 126 | }; |
| 124 | 127 | ||
| 125 | class IDebugFunctions final : public ServiceFramework<IDebugFunctions> { | 128 | class IDebugFunctions final : public ServiceFramework<IDebugFunctions> { |
| @@ -303,7 +306,9 @@ public: | |||
| 303 | 306 | ||
| 304 | private: | 307 | private: |
| 305 | void PopInData(HLERequestContext& ctx); | 308 | void PopInData(HLERequestContext& ctx); |
| 309 | void PushOutData(HLERequestContext& ctx); | ||
| 306 | void GetLibraryAppletInfo(HLERequestContext& ctx); | 310 | void GetLibraryAppletInfo(HLERequestContext& ctx); |
| 311 | void ExitProcessAndReturn(HLERequestContext& ctx); | ||
| 307 | void GetCallerAppletIdentityInfo(HLERequestContext& ctx); | 312 | void GetCallerAppletIdentityInfo(HLERequestContext& ctx); |
| 308 | 313 | ||
| 309 | void PushInShowMiiEditData(); | 314 | void PushInShowMiiEditData(); |