Changeset 085bd54 in mainline for tetris/screen.c


Ignore:
Timestamp:
2006-06-06T15:16:08Z (19 years ago)
Author:
Ondrej Palkovsky <ondrap@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
63bb83e
Parents:
d7eafd8
Message:

Revised ipc. Now it is preferrable to use only functions from async.h, they
take care of correct buffering, waiting for answers etc.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tetris/screen.c

    rd7eafd8 r085bd54  
    8181static void set_style(int fgcolor, int bgcolor)
    8282{
    83         send_call_2(con_phone, CONSOLE_SET_STYLE, fgcolor, bgcolor);
     83        async_msg_2(con_phone, CONSOLE_SET_STYLE, fgcolor, bgcolor);
    8484}
    8585
     
    9797void clear_screen(void)
    9898{
    99         send_call(con_phone, CONSOLE_CLEAR, 0);
     99        async_msg(con_phone, CONSOLE_CLEAR, 0);
    100100        moveto(0,0);
    101101}
     
    109109
    110110        resume_normal();
    111         send_call(con_phone, CONSOLE_CLEAR, 0);
     111        async_msg(con_phone, CONSOLE_CLEAR, 0);
    112112        curscore = -1;
    113113        memset((char *)curscreen, 0, sizeof(curscreen));
     
    121121{
    122122        con_phone = get_fd_phone(1);
    123         send_call(con_phone, CONSOLE_CURSOR_VISIBILITY, 0);
     123        async_msg(con_phone, CONSOLE_CURSOR_VISIBILITY, 0);
    124124        resume_normal();
    125125        scr_clear();
     
    128128void moveto(int r, int c)
    129129{
    130         send_call_2(con_phone, CONSOLE_GOTO, r, c);
     130        async_msg_2(con_phone, CONSOLE_GOTO, r, c);
    131131}
    132132
    133133static void fflush(void)
    134134{
    135         send_call(con_phone, CONSOLE_FLUSH, 0);
     135        async_msg(con_phone, CONSOLE_FLUSH, 0);
    136136}
    137137
     
    140140static int get_display_size(winsize_t *ws)
    141141{
    142         return sync_send_2(con_phone, CONSOLE_GETSIZE, 0, 0, &ws->ws_row, &ws->ws_col);
     142        return async_req_2(con_phone, CONSOLE_GETSIZE, 0, 0, &ws->ws_row, &ws->ws_col);
    143143}
    144144
Note: See TracChangeset for help on using the changeset viewer.