Changeset 3596 for libcaca


Ignore:
Timestamp:
Jul 31, 2009, 2:01:32 AM (10 years ago)
Author:
Sam Hocevar
Message:

Implement conio.h's getche() and move cursor to top right corner after
a call to clrscr().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcaca/trunk/caca/caca_conio.c

    r3595 r3596  
    6666
    6767    caca_clear_canvas(cv);
     68    caca_gotoxy(cv, 0, 0);
    6869
    6970    conio_refresh();
     
    153154int caca_conio_getche(void)
    154155{
    155     conio_init();
    156 
    157     /* TODO: implement this function */
    158 
    159     return 0;
     156    /* conio_init() is called here. */
     157    int tmp = caca_conio_getch();
     158    /* conio_refresh() is called here. */
     159    caca_conio_printf("%c", tmp);
     160
     161    return tmp;
    160162}
    161163
Note: See TracChangeset for help on using the changeset viewer.