diff options
| author | 2018-11-02 12:35:49 +1100 | |
|---|---|---|
| committer | 2018-11-02 12:35:49 +1100 | |
| commit | 0bc323bafb79442ead1511a5d7ee08f1caff171a (patch) | |
| tree | 4f3bd752e6cec4d209dfc245338911c08fa0fb0e | |
| parent | Merge pull request #1615 from lioncash/input (diff) | |
| download | yuzu-0bc323bafb79442ead1511a5d7ee08f1caff171a.tar.gz yuzu-0bc323bafb79442ead1511a5d7ee08f1caff171a.tar.xz yuzu-0bc323bafb79442ead1511a5d7ee08f1caff171a.zip | |
Fixed HID crash when launching more than 1 game & signaled syleset change event
This should fix crashes when launching multiple games in yuzu
Diffstat (limited to '')
| -rw-r--r-- | src/core/hle/service/hid/controllers/npad.cpp | 3 | ||||
| -rw-r--r-- | src/core/hle/service/hid/hid.cpp | 2 |
2 files changed, 5 insertions, 0 deletions
diff --git a/src/core/hle/service/hid/controllers/npad.cpp b/src/core/hle/service/hid/controllers/npad.cpp index 4b4d1324f..1ef789bd0 100644 --- a/src/core/hle/service/hid/controllers/npad.cpp +++ b/src/core/hle/service/hid/controllers/npad.cpp | |||
| @@ -427,6 +427,9 @@ void Controller_NPad::VibrateController(const std::vector<u32>& controller_ids, | |||
| 427 | } | 427 | } |
| 428 | 428 | ||
| 429 | Kernel::SharedPtr<Kernel::Event> Controller_NPad::GetStyleSetChangedEvent() const { | 429 | Kernel::SharedPtr<Kernel::Event> Controller_NPad::GetStyleSetChangedEvent() const { |
| 430 | // TODO(ogniK): Figure out the best time to signal this event. This event seems that it should | ||
| 431 | // be signalled at least once, and signaled after a new controller is connected? | ||
| 432 | styleset_changed_event->Signal(); | ||
| 430 | return styleset_changed_event; | 433 | return styleset_changed_event; |
| 431 | } | 434 | } |
| 432 | 435 | ||
diff --git a/src/core/hle/service/hid/hid.cpp b/src/core/hle/service/hid/hid.cpp index a9aa9ec78..a45fd4954 100644 --- a/src/core/hle/service/hid/hid.cpp +++ b/src/core/hle/service/hid/hid.cpp | |||
| @@ -96,6 +96,8 @@ public: | |||
| 96 | // TODO(shinyquagsire23): Other update callbacks? (accel, gyro?) | 96 | // TODO(shinyquagsire23): Other update callbacks? (accel, gyro?) |
| 97 | 97 | ||
| 98 | CoreTiming::ScheduleEvent(pad_update_ticks, pad_update_event); | 98 | CoreTiming::ScheduleEvent(pad_update_ticks, pad_update_event); |
| 99 | |||
| 100 | ReloadInputDevices(); | ||
| 99 | } | 101 | } |
| 100 | 102 | ||
| 101 | void ActivateController(HidController controller) { | 103 | void ActivateController(HidController controller) { |