diff options
| author | liamwhite <liamwhite@users.noreply.github.com> | 2024-02-23 11:34:29 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-02-23 11:34:29 -0500 |
| commit | fa4dec9fe9ff67b0a4f73953b18f0cd7e1698bd5 (patch) | |
| tree | 04d960417c9c4aef9108b8640ebf4e82fc3f28a1 /src/core/hle/service/pctl/pctl.cpp | |
| parent | 215e887be088ed572da999e9ec7fd8559198524b (diff) | |
| parent | 89c2fd3d2830d5b1e73c9e051e4af39772963036 (diff) | |
Merge pull request #13115 from liamwhite/olsc-pctl
olsc, pctl: move to new ipc
Diffstat (limited to 'src/core/hle/service/pctl/pctl.cpp')
| -rw-r--r-- | src/core/hle/service/pctl/pctl.cpp | 27 |
1 files changed, 18 insertions, 9 deletions
diff --git a/src/core/hle/service/pctl/pctl.cpp b/src/core/hle/service/pctl/pctl.cpp index 3f47bf094..d92dbe216 100644 --- a/src/core/hle/service/pctl/pctl.cpp +++ b/src/core/hle/service/pctl/pctl.cpp @@ -1,19 +1,28 @@ // SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project // SPDX-License-Identifier: GPL-2.0-or-later +#include "core/hle/service/pctl/parental_control_service_factory.h" #include "core/hle/service/pctl/pctl.h" +#include "core/hle/service/server_manager.h" namespace Service::PCTL { -PCTL::PCTL(Core::System& system_, std::shared_ptr<Module> module_, const char* name, - Capability capability_) - : Interface{system_, std::move(module_), name, capability_} { - static const FunctionInfo functions[] = { - {0, &PCTL::CreateService, "CreateService"}, - {1, &PCTL::CreateServiceWithoutInitialize, "CreateServiceWithoutInitialize"}, - }; - RegisterHandlers(functions); +void LoopProcess(Core::System& system) { + auto server_manager = std::make_unique<ServerManager>(system); + + server_manager->RegisterNamedService("pctl", + std::make_shared<IParentalControlServiceFactory>( + system, "pctl", + Capability::Application | Capability::SnsPost | + Capability::Status | Capability::StereoVision)); + // TODO(ogniK): Implement remaining capabilities + server_manager->RegisterNamedService("pctl:a", std::make_shared<IParentalControlServiceFactory>( + system, "pctl:a", Capability::None)); + server_manager->RegisterNamedService("pctl:r", std::make_shared<IParentalControlServiceFactory>( + system, "pctl:r", Capability::None)); + server_manager->RegisterNamedService("pctl:s", std::make_shared<IParentalControlServiceFactory>( + system, "pctl:s", Capability::None)); + ServerManager::RunServer(std::move(server_manager)); } -PCTL::~PCTL() = default; } // namespace Service::PCTL |
