diff --git a/src/Ryujinx.HLE/HOS/Applets/AppletManager.cs b/src/Ryujinx.HLE/HOS/Applets/AppletManager.cs index 1ec3353ca..132532be9 100644 --- a/src/Ryujinx.HLE/HOS/Applets/AppletManager.cs +++ b/src/Ryujinx.HLE/HOS/Applets/AppletManager.cs @@ -24,6 +24,8 @@ namespace Ryujinx.HLE.HOS.Applets case AppletId.LibAppletWeb: case AppletId.LibAppletShop: case AppletId.LibAppletOff: + case AppletId.LibAppletOffFw17: + case AppletId.LibAppletOff2Fw17: return new BrowserApplet(); case AppletId.Cabinet: return new CabinetApplet(system); diff --git a/src/Ryujinx.HLE/HOS/Applets/WindowSystem.cs b/src/Ryujinx.HLE/HOS/Applets/WindowSystem.cs index a976573da..95b9ecde8 100644 --- a/src/Ryujinx.HLE/HOS/Applets/WindowSystem.cs +++ b/src/Ryujinx.HLE/HOS/Applets/WindowSystem.cs @@ -318,20 +318,21 @@ namespace Ryujinx.HLE.HOS.Applets private void SendButtonAppletMessageLocked(AppletMessage message) { + if (message == AppletMessage.DetectShortPressingHomeButton) + { + foreach (var applet in _applets.Values) + { + if (applet != _homeMenu && applet != _overlayDisp && _foregroundRequestedApplet==applet) + { + applet.ProcessHandle.SetActivity(true); + } + } + } + if (_homeMenu != null) { lock (_homeMenu.Lock) { - if (message == AppletMessage.DetectShortPressingHomeButton) - { - foreach (var applet in _applets.Values) - { - if (applet != _homeMenu && _foregroundRequestedApplet==applet) - { - applet.ProcessHandle.SetActivity(true); - } - } - } _homeMenu.AppletState.PushUnorderedMessage(message); } } @@ -621,7 +622,7 @@ namespace Ryujinx.HLE.HOS.Applets public void PauseOldWindows(ulong pid) { RealApplet applet = GetByAruId(pid); - if (applet?.CallerApplet != null&&applet?.CallerApplet!=_homeMenu) + if (applet?.CallerApplet != null&&applet?.CallerApplet!=_homeMenu&&applet?.CallerApplet!=_overlayDisp) { applet.CallerApplet.ProcessHandle.SetActivity(true); } diff --git a/src/Ryujinx.HLE/HOS/Services/Am/AppletAE/AllSystemAppletProxiesService/SystemAppletProxy/ICommonStateGetter.cs b/src/Ryujinx.HLE/HOS/Services/Am/AppletAE/AllSystemAppletProxiesService/SystemAppletProxy/ICommonStateGetter.cs index c3a6fe27c..e2d4ba628 100644 --- a/src/Ryujinx.HLE/HOS/Services/Am/AppletAE/AllSystemAppletProxiesService/SystemAppletProxy/ICommonStateGetter.cs +++ b/src/Ryujinx.HLE/HOS/Services/Am/AppletAE/AllSystemAppletProxiesService/SystemAppletProxy/ICommonStateGetter.cs @@ -318,6 +318,14 @@ namespace Ryujinx.HLE.HOS.Services.Am.AppletAE.AllSystemAppletProxiesService.Sys return ResultCode.Success; } + + [CommandCmif(68)] + // GetBuiltInDisplayType() -> u32 type + public ResultCode GetBuiltInDisplayType(ServiceCtx context) + { + context.ResponseData.Write(0); + return ResultCode.Success; + } [CommandCmif(91)] // 7.0.0+ // GetCurrentPerformanceConfiguration() -> nn::apm::PerformanceConfiguration diff --git a/src/Ryujinx.HLE/HOS/Services/Am/AppletAE/Types/AppletId.cs b/src/Ryujinx.HLE/HOS/Services/Am/AppletAE/Types/AppletId.cs index d9970341f..67ad4d294 100644 --- a/src/Ryujinx.HLE/HOS/Services/Am/AppletAE/Types/AppletId.cs +++ b/src/Ryujinx.HLE/HOS/Services/Am/AppletAE/Types/AppletId.cs @@ -20,6 +20,8 @@ namespace Ryujinx.HLE.HOS.Services.Am.AppletAE PhotoViewer = 0x15, Settings = 0x16, LibAppletOff = 0x17, + LibAppletOffFw17 = 0x32, + LibAppletOff2Fw17 = 0x33, LibAppletWhitelisted = 0x18, LibAppletAuth = 0x19, MyPage = 0x1A, diff --git a/src/Ryujinx.HLE/HOS/Services/Audio/IAudioController.cs b/src/Ryujinx.HLE/HOS/Services/Audio/IAudioController.cs index 89dfad2ac..23cd3f421 100644 --- a/src/Ryujinx.HLE/HOS/Services/Audio/IAudioController.cs +++ b/src/Ryujinx.HLE/HOS/Services/Audio/IAudioController.cs @@ -1,4 +1,6 @@ using Ryujinx.Common.Logging; +using Ryujinx.HLE.HOS.Ipc; +using Ryujinx.HLE.HOS.Kernel.Threading; namespace Ryujinx.HLE.HOS.Services.Audio { @@ -80,6 +82,16 @@ namespace Ryujinx.HLE.HOS.Services.Audio return ResultCode.Success; } + [CommandCmif(34)] + // AcquireTargetNotification() -> handle + public ResultCode AcquireTargetNotification(ServiceCtx context) + { + KEvent ev = new KEvent(context.Device.System.KernelContext); + context.Process.HandleTable.GenerateHandle(ev.ReadableEvent, out int handle); + context.Response.HandleDesc = IpcHandleDesc.MakeCopy(handle); + return ResultCode.Success; + } + [CommandCmif(5000)] // Unknown5000() -> bool // 19.0.0+ public ResultCode Unknown5000(ServiceCtx context) diff --git a/src/Ryujinx/AppHost.cs b/src/Ryujinx/AppHost.cs index d232790dd..2ddb49eb0 100644 --- a/src/Ryujinx/AppHost.cs +++ b/src/Ryujinx/AppHost.cs @@ -967,7 +967,7 @@ namespace Ryujinx.Ava ConfigurationState.Instance.Multiplayer.LdnServer, ConfigurationState.Instance.Graphics.CustomVSyncInterval.Value, ConfigurationState.Instance.Hacks.ShowDirtyHacks ? ConfigurationState.Instance.Hacks.EnabledHacks : null)); - //Device.LoadSystemProgramId(0x010000000000100C); + Device.LoadSystemProgramId(0x010000000000100C); } private static IHardwareDeviceDriver InitializeAudio()