repo.or.cz
/
chuck-blob.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
*** empty log message ***
[chuck-blob.git]
/
v2
/
examples
/
event
/
kb.ck
blob
9d585a0e5f117912b5ce474d6c78540940cf39a9
1
// the event
2
KBHit kb;
3
4
// time-loop
5
while( true )
6
{
7
// wait on kbhit event
8
kb => now;
9
10
// potentially more than 1 key at a time
11
while( kb.more() )
12
{
13
// print key value
14
<<< "ascii: ", kb.getchar() >>>;
15
}
16
}
17