| Line |  | 
|---|
| 1 | #include <stdio.h> | 
|---|
| 2 | #include <stdlib.h> | 
|---|
| 3 | #include <string.h> | 
|---|
| 4 | #define  INCL_DOS | 
|---|
| 5 | #define  INCL_WIN | 
|---|
| 6 | #define  INCL_BASE | 
|---|
| 7 | #include <os2.h> | 
|---|
| 8 | #include "vio32.h" | 
|---|
| 9 |  | 
|---|
| 10 |  | 
|---|
| 11 | void main(int argc, char **argv){ | 
|---|
| 12 |  | 
|---|
| 13 |  | 
|---|
| 14 | vio32Open(); | 
|---|
| 15 | kbd32SetMode(KBD32MODE_DISABLEBREAK | KBD32MODE_ENABLEMOUSE | KBD32MODE_ENABLEMMOVE); | 
|---|
| 16 |  | 
|---|
| 17 |  | 
|---|
| 18 | printf("\n"); | 
|---|
| 19 | VIO32EVENTINFO event; | 
|---|
| 20 | ULONG eventType; | 
|---|
| 21 | while(1){ | 
|---|
| 22 | BOOL ret = vio32GetEvent(&event,&eventType,-1); | 
|---|
| 23 | if (ret==0){ | 
|---|
| 24 | printf("%x\n",eventType); | 
|---|
| 25 | } else DosSleep(100); | 
|---|
| 26 | } | 
|---|
| 27 |  | 
|---|
| 28 | vio32Close(); | 
|---|
| 29 |  | 
|---|
| 30 |  | 
|---|
| 31 | } | 
|---|
       
      
  Note:
 See   
TracBrowser
 for help on using the repository browser.