mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2025-07-01 13:47:56 -05:00
web_browser: Add bounds checking to applet interface
This commit is contained in:
@ -638,10 +638,8 @@ void Controller_NPad::ClearAllControllers() {
|
||||
});
|
||||
}
|
||||
|
||||
u32 Controller_NPad::GetPressState() {
|
||||
const auto res = press_state;
|
||||
press_state = 0;
|
||||
return res;
|
||||
u32 Controller_NPad::GetAndResetPressState() {
|
||||
return std::exchange(press_state, 0);
|
||||
}
|
||||
|
||||
bool Controller_NPad::IsControllerSupported(NPadControllerType controller) const {
|
||||
|
@ -126,7 +126,7 @@ public:
|
||||
|
||||
// Logical OR for all buttons presses on all controllers
|
||||
// Specifically for cheat engine and other features.
|
||||
u32 GetPressState();
|
||||
u32 GetAndResetPressState();
|
||||
|
||||
static std::size_t NPadIdToIndex(u32 npad_id);
|
||||
static u32 IndexToNPad(std::size_t index);
|
||||
|
Reference in New Issue
Block a user