From 76e78a1bc4ac853ce242808f7a5b8dbdda450bf6 Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Wed, 28 Dec 2005 19:21:01 +0000 Subject: [PATCH] avoid iterating over all buttons --- stepmania/src/InputFilter.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/stepmania/src/InputFilter.cpp b/stepmania/src/InputFilter.cpp index af846c978a..42446119a2 100644 --- a/stepmania/src/InputFilter.cpp +++ b/stepmania/src/InputFilter.cpp @@ -131,9 +131,14 @@ void InputFilter::SetButtonComment( const DeviceInput &di, const CString &sComme /* Release all buttons on the given device. */ void InputFilter::ResetDevice( InputDevice device ) { + LockMut(*queuemutex); RageTimer now; - FOREACH_ENUM2( DeviceButton, button ) - ButtonPressed( DeviceInput(device, button, -1, now), false ); + set