浏览代码

* issue sleep while polling keyboard

git-svn-id: trunk@8690 -
Tomas Hajny 18 年之前
父节点
当前提交
e70f1a26db
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      rtl/os2/keyboard.pp

+ 2 - 2
rtl/os2/keyboard.pp

@@ -63,8 +63,8 @@ var
  K: TKbdKeyInfo;
  K: TKbdKeyInfo;
 begin
 begin
   KbdGetFocus (IO_Wait, Handle);
   KbdGetFocus (IO_Wait, Handle);
-  while (KbdCharIn (K, IO_Wait, Handle) <> No_Error)
-        or (K.fbStatus and $40 = 0) do
+  while (KbdCharIn (K, IO_NoWait, Handle) <> No_Error)
+        or (K.fbStatus and $41 <> $40) do
     DosSleep (5);
     DosSleep (5);
   with K do
   with K do
     begin
     begin