Added a function that clears the keyboard buffer.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@9958 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -33,6 +33,14 @@ check_for_key(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
extern "C" void
|
||||||
|
clear_key_buffer(void)
|
||||||
|
{
|
||||||
|
while (check_for_key() != 0)
|
||||||
|
;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
extern "C" union key
|
extern "C" union key
|
||||||
wait_for_key(void)
|
wait_for_key(void)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -26,6 +26,7 @@ union key {
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
extern void clear_key_buffer(void);
|
||||||
extern union key wait_for_key(void);
|
extern union key wait_for_key(void);
|
||||||
extern uint32 check_for_boot_keys(void);
|
extern uint32 check_for_boot_keys(void);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user