test/testkeys.c
author Holmes Futrell <hfutrell@umail.ucsb.edu>
Fri, 18 Jul 2008 19:23:13 +0000
branchgsoc2008_iphone
changeset 2377 e9a0bad0ea07
parent 2306 1a8bab15a45d
child 5081 25d4feb7c127
permissions -rw-r--r--
Just renamed it...
     1 
     2 /* Print out all the scancodes we have, just to verify them */
     3 
     4 #include <stdio.h>
     5 #include <ctype.h>
     6 #include <stdlib.h>
     7 #include <string.h>
     8 
     9 #include "SDL.h"
    10 
    11 int
    12 main(int argc, char *argv[])
    13 {
    14     SDL_scancode scancode;
    15 
    16     if (SDL_Init(SDL_INIT_VIDEO) < 0) {
    17         fprintf(stderr, "Couldn't initialize SDL: %s\n", SDL_GetError());
    18         exit(1);
    19     }
    20     for (scancode = 0; scancode < SDL_NUM_SCANCODES; ++scancode) {
    21         printf("Scancode #%d, \"%s\"\n", scancode,
    22                SDL_GetScancodeName(scancode));
    23     }
    24     SDL_Quit();
    25     return (0);
    26 }