mirror of
https://github.com/stenzek/duckstation.git
synced 2026-02-15 10:54:36 +00:00
InputManager: Fix raw input not registering
This commit is contained in:
@@ -335,7 +335,14 @@ bool Win32RawInputSource::ReloadDevices()
|
||||
while (!m_mice.empty() && !m_mice.back().device)
|
||||
m_mice.pop_back();
|
||||
|
||||
DEV_LOG("Found {} mice", std::ranges::count_if(m_mice, [](const MouseState& ms) { return (ms.device != nullptr); }));
|
||||
const size_t num_mice = std::ranges::count_if(m_mice, [](const MouseState& ms) { return (ms.device != nullptr); });
|
||||
DEV_LOG("Found {} mice", num_mice);
|
||||
|
||||
if (num_mice > 0)
|
||||
EnsureRawInputRegistered();
|
||||
else
|
||||
UnregisterRawInput();
|
||||
|
||||
return any_changed;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user