mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 12:32:20 +02:00
Fix keyDown check, remove debug string from key release timeout
This commit is contained in:
parent
54dc59e049
commit
35d82fd599
1 changed files with 7 additions and 7 deletions
|
@ -449,18 +449,18 @@ bool WinBFWindow::CheckKeyReleases(bool isKeyDown)
|
|||
bool hasKeyDown = false;
|
||||
uint8 keysDown[256] = { 0 };
|
||||
::GetKeyboardState((PBYTE)&keysDown);
|
||||
for (int i = 0; i < 256; i++)
|
||||
for (int i = 1; i < 256; i++)
|
||||
if (keysDown[i] & 0x80)
|
||||
hasKeyDown = true;
|
||||
|
||||
if ((hasKeyDown) && (::GetTickCount() - mAwaitKeyReleasesEventTick >= 600))
|
||||
{
|
||||
String dbgStr = "CheckKeyReleases timeout. Keys down:";
|
||||
for (int i = 0; i < 256; i++)
|
||||
if (keysDown[i] & 0x80)
|
||||
dbgStr += StrFormat(" %2X", i);
|
||||
dbgStr += "\n";
|
||||
OutputDebugStr(dbgStr);
|
||||
// String dbgStr = "CheckKeyReleases timeout. Keys down:";
|
||||
// for (int i = 1; i < 256; i++)
|
||||
// if (keysDown[i] & 0x80)
|
||||
// dbgStr += StrFormat(" %2X", i);
|
||||
// dbgStr += "\n";
|
||||
// OutputDebugStr(dbgStr);
|
||||
hasKeyDown = false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue