diff options
author | bunnei <bunneidev@gmail.com> | 2015-04-28 04:01:48 +0200 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2015-05-02 00:27:02 +0200 |
commit | e0cb85691a99fb06dbce5e802ae756a944b1a66c (patch) | |
tree | d82acb9b470acec2f5faf5b2c6d9ea7cd6982018 /src/core/hle/service/hid | |
parent | Memory: Properly cleanup & shutdown. (diff) | |
download | yuzu-e0cb85691a99fb06dbce5e802ae756a944b1a66c.tar yuzu-e0cb85691a99fb06dbce5e802ae756a944b1a66c.tar.gz yuzu-e0cb85691a99fb06dbce5e802ae756a944b1a66c.tar.bz2 yuzu-e0cb85691a99fb06dbce5e802ae756a944b1a66c.tar.lz yuzu-e0cb85691a99fb06dbce5e802ae756a944b1a66c.tar.xz yuzu-e0cb85691a99fb06dbce5e802ae756a944b1a66c.tar.zst yuzu-e0cb85691a99fb06dbce5e802ae756a944b1a66c.zip |
Diffstat (limited to 'src/core/hle/service/hid')
-rw-r--r-- | src/core/hle/service/hid/hid.cpp | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/src/core/hle/service/hid/hid.cpp b/src/core/hle/service/hid/hid.cpp index 9ca5d13d4..0f30f743a 100644 --- a/src/core/hle/service/hid/hid.cpp +++ b/src/core/hle/service/hid/hid.cpp @@ -20,17 +20,17 @@ namespace HID { static const int MAX_CIRCLEPAD_POS = 0x9C; ///< Max value for a circle pad position // Handle to shared memory region designated to HID_User service -static Kernel::SharedPtr<Kernel::SharedMemory> shared_mem = nullptr; +static Kernel::SharedPtr<Kernel::SharedMemory> shared_mem; // Event handles -static Kernel::SharedPtr<Kernel::Event> event_pad_or_touch_1 = nullptr; -static Kernel::SharedPtr<Kernel::Event> event_pad_or_touch_2 = nullptr; -static Kernel::SharedPtr<Kernel::Event> event_accelerometer = nullptr; -static Kernel::SharedPtr<Kernel::Event> event_gyroscope = nullptr; -static Kernel::SharedPtr<Kernel::Event> event_debug_pad = nullptr; +static Kernel::SharedPtr<Kernel::Event> event_pad_or_touch_1; +static Kernel::SharedPtr<Kernel::Event> event_pad_or_touch_2; +static Kernel::SharedPtr<Kernel::Event> event_accelerometer; +static Kernel::SharedPtr<Kernel::Event> event_gyroscope; +static Kernel::SharedPtr<Kernel::Event> event_debug_pad; -static u32 next_pad_index = 0; -static u32 next_touch_index = 0; +static u32 next_pad_index; +static u32 next_touch_index; // TODO(peachum): // Add a method for setting analog input from joystick device for the circle Pad. @@ -175,6 +175,12 @@ void Init() { } void Shutdown() { + shared_mem = nullptr; + event_pad_or_touch_1 = nullptr; + event_pad_or_touch_2 = nullptr; + event_accelerometer = nullptr; + event_gyroscope = nullptr; + event_debug_pad = nullptr; } } // namespace HID |