diff options
author | David Marcec <dmarcecguzman@gmail.com> | 2020-04-29 13:48:58 +0200 |
---|---|---|
committer | David Marcec <dmarcecguzman@gmail.com> | 2020-04-29 13:48:58 +0200 |
commit | 8bddc750e283b13da19f719be4671ee2c8230b8a (patch) | |
tree | 9f2fad37b1fd8caae7fbb50eb61a126287cf63eb /src/core/hle/service/am | |
parent | Merge pull request #3771 from benru/dump-romfs-with-updates (diff) | |
download | yuzu-8bddc750e283b13da19f719be4671ee2c8230b8a.tar yuzu-8bddc750e283b13da19f719be4671ee2c8230b8a.tar.gz yuzu-8bddc750e283b13da19f719be4671ee2c8230b8a.tar.bz2 yuzu-8bddc750e283b13da19f719be4671ee2c8230b8a.tar.lz yuzu-8bddc750e283b13da19f719be4671ee2c8230b8a.tar.xz yuzu-8bddc750e283b13da19f719be4671ee2c8230b8a.tar.zst yuzu-8bddc750e283b13da19f719be4671ee2c8230b8a.zip |
Diffstat (limited to 'src/core/hle/service/am')
-rw-r--r-- | src/core/hle/service/am/am.cpp | 21 | ||||
-rw-r--r-- | src/core/hle/service/am/am.h | 1 |
2 files changed, 6 insertions, 16 deletions
diff --git a/src/core/hle/service/am/am.cpp b/src/core/hle/service/am/am.cpp index 5695d2521..1eb990f8b 100644 --- a/src/core/hle/service/am/am.cpp +++ b/src/core/hle/service/am/am.cpp @@ -52,11 +52,6 @@ enum class LaunchParameterKind : u32 { AccountPreselectedUser = 2, }; -enum class VrMode : u8 { - Disabled = 0, - Enabled = 1, -}; - constexpr u32 LAUNCH_PARAMETER_ACCOUNT_PRESELECTED_USER_MAGIC = 0xC79497CA; struct LaunchParameterAccountPreselectedUser { @@ -685,27 +680,21 @@ void ICommonStateGetter::GetCurrentFocusState(Kernel::HLERequestContext& ctx) { } void ICommonStateGetter::IsVrModeEnabled(Kernel::HLERequestContext& ctx) { - LOG_WARNING(Service_AM, "(STUBBED) called"); + LOG_DEBUG(Service_AM, "called"); IPC::ResponseBuilder rb{ctx, 3}; rb.Push(RESULT_SUCCESS); - rb.PushEnum(VrMode::Disabled); + rb.Push(vr_mode_state); } void ICommonStateGetter::SetVrModeEnabled(Kernel::HLERequestContext& ctx) { IPC::RequestParser rp{ctx}; - const auto is_vr_mode_enabled = rp.Pop<bool>(); + vr_mode_state = rp.Pop<bool>(); - LOG_WARNING(Service_AM, "(STUBBED) called. is_vr_mode_enabled={}", is_vr_mode_enabled); + LOG_WARNING(Service_AM, "VR Mode is {}", vr_mode_state ? "on" : "off"); IPC::ResponseBuilder rb{ctx, 2}; - if (!is_vr_mode_enabled) { - rb.Push(RESULT_SUCCESS); - } else { - // TODO: Find better error code for this - UNIMPLEMENTED_MSG("is_vr_mode_enabled={}", is_vr_mode_enabled); - rb.Push(RESULT_UNKNOWN); - } + rb.Push(RESULT_SUCCESS); } void ICommonStateGetter::SetLcdBacklighOffEnabled(Kernel::HLERequestContext& ctx) { diff --git a/src/core/hle/service/am/am.h b/src/core/hle/service/am/am.h index 53cfce10f..25eb13ce0 100644 --- a/src/core/hle/service/am/am.h +++ b/src/core/hle/service/am/am.h @@ -191,6 +191,7 @@ private: Core::System& system; std::shared_ptr<AppletMessageQueue> msg_queue; + bool vr_mode_state{}; }; class IStorageImpl { |