diff options
Diffstat (limited to 'src/core/hle/service/am/service/all_system_applet_proxies_service.h')
-rw-r--r-- | src/core/hle/service/am/service/all_system_applet_proxies_service.h | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/src/core/hle/service/am/service/all_system_applet_proxies_service.h b/src/core/hle/service/am/service/all_system_applet_proxies_service.h new file mode 100644 index 000000000..38b1ca2ea --- /dev/null +++ b/src/core/hle/service/am/service/all_system_applet_proxies_service.h @@ -0,0 +1,47 @@ +// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#include "core/hle/service/cmif_types.h" +#include "core/hle/service/service.h" + +namespace Service { + +namespace Nvnflinger { +class Nvnflinger; +} + +namespace AM { + +struct Applet; +struct AppletAttribute; +class ILibraryAppletProxy; +class ISystemAppletProxy; + +class IAllSystemAppletProxiesService final + : public ServiceFramework<IAllSystemAppletProxiesService> { +public: + explicit IAllSystemAppletProxiesService(Core::System& system_, + Nvnflinger::Nvnflinger& nvnflinger); + ~IAllSystemAppletProxiesService() override; + +private: + Result OpenSystemAppletProxy(Out<SharedPointer<ISystemAppletProxy>> out_system_applet_proxy, + ClientProcessId pid, + InCopyHandle<Kernel::KProcess> process_handle); + Result OpenLibraryAppletProxy(Out<SharedPointer<ILibraryAppletProxy>> out_library_applet_proxy, + ClientProcessId pid, + InCopyHandle<Kernel::KProcess> process_handle, + InLargeData<AppletAttribute, BufferAttr_HipcMapAlias> attribute); + Result OpenLibraryAppletProxyOld( + Out<SharedPointer<ILibraryAppletProxy>> out_library_applet_proxy, ClientProcessId pid, + InCopyHandle<Kernel::KProcess> process_handle); + +private: + std::shared_ptr<Applet> GetAppletFromProcessId(ProcessId pid); + Nvnflinger::Nvnflinger& m_nvnflinger; +}; + +} // namespace AM +} // namespace Service |