diff options
author | Amar Takhar <mplayer@darkbeer.org> | 2009-07-07 01:15:02 +0300 |
---|---|---|
committer | Uoti Urpala <uau@glyph.nonexistent.invalid> | 2009-07-07 01:38:20 +0300 |
commit | e306174952d42e1cd6cc5efc50ae6bb0410501bc (patch) | |
tree | a7eb451f2c634f17d8e36a72b6305c1aff508904 /input/joystick.c | |
parent | b5972d6f14c04384d88d3f813b435d484562403f (diff) | |
download | mpv-e306174952d42e1cd6cc5efc50ae6bb0410501bc.tar.bz2 mpv-e306174952d42e1cd6cc5efc50ae6bb0410501bc.tar.xz |
Translation system changes part 2: replace macros by strings
Replace all MSGTR_ macros in the source by the corresponding English
string.
Diffstat (limited to 'input/joystick.c')
-rw-r--r-- | input/joystick.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/input/joystick.c b/input/joystick.c index c2a1e91de1..b6e5e43784 100644 --- a/input/joystick.c +++ b/input/joystick.c @@ -51,11 +51,11 @@ int mp_input_joystick_init(char* dev) { int initialized = 0; struct js_event ev; - mp_tmsg(MSGT_INPUT,MSGL_V,MSGTR_INPUT_JOYSTICK_Opening,dev ? dev : JS_DEV); + mp_tmsg(MSGT_INPUT,MSGL_V,"Opening joystick device %s\n",dev ? dev : JS_DEV); fd = open( dev ? dev : JS_DEV , O_RDONLY | O_NONBLOCK ); if(fd < 0) { - mp_tmsg(MSGT_INPUT,MSGL_ERR,MSGTR_INPUT_JOYSTICK_CantOpen,dev ? dev : JS_DEV,strerror(errno)); + mp_tmsg(MSGT_INPUT,MSGL_ERR,"Can't open joystick device %s: %s\n",dev ? dev : JS_DEV,strerror(errno)); return -1; } @@ -70,7 +70,7 @@ int mp_input_joystick_init(char* dev) { initialized = 1; break; } - mp_tmsg(MSGT_INPUT,MSGL_ERR,MSGTR_INPUT_JOYSTICK_ErrReading,strerror(errno)); + mp_tmsg(MSGT_INPUT,MSGL_ERR,"Error while reading joystick device: %s\n",strerror(errno)); close(fd); return -1; } @@ -78,7 +78,7 @@ int mp_input_joystick_init(char* dev) { } if((unsigned int)l < sizeof(struct js_event)) { if(l > 0) - mp_tmsg(MSGT_INPUT,MSGL_WARN,MSGTR_INPUT_JOYSTICK_LoosingBytes,l); + mp_tmsg(MSGT_INPUT,MSGL_WARN,"Joystick: We lose %d bytes of data\n",l); break; } if(ev.type == JS_EVENT_BUTTON) @@ -102,9 +102,9 @@ int mp_input_joystick_read(void *ctx, int fd) { else if(errno == EAGAIN) return MP_INPUT_NOTHING; if( r < 0) - mp_tmsg(MSGT_INPUT,MSGL_ERR,MSGTR_INPUT_JOYSTICK_ErrReading,strerror(errno)); + mp_tmsg(MSGT_INPUT,MSGL_ERR,"Error while reading joystick device: %s\n",strerror(errno)); else - mp_tmsg(MSGT_INPUT,MSGL_ERR,MSGTR_INPUT_JOYSTICK_ErrReading,"EOF"); + mp_tmsg(MSGT_INPUT,MSGL_ERR,"Error while reading joystick device: %s\n","EOF"); return MP_INPUT_DEAD; } l += r; @@ -112,12 +112,12 @@ int mp_input_joystick_read(void *ctx, int fd) { if((unsigned int)l < sizeof(struct js_event)) { if(l > 0) - mp_tmsg(MSGT_INPUT,MSGL_WARN,MSGTR_INPUT_JOYSTICK_LoosingBytes,l); + mp_tmsg(MSGT_INPUT,MSGL_WARN,"Joystick: We lose %d bytes of data\n",l); return MP_INPUT_NOTHING; } if(ev.type & JS_EVENT_INIT) { - mp_tmsg(MSGT_INPUT,MSGL_WARN,MSGTR_INPUT_JOYSTICK_WarnLostSync); + mp_tmsg(MSGT_INPUT,MSGL_WARN,"Joystick: warning init event, we have lost sync with driver.\n"); ev.type &= ~JS_EVENT_INIT; if(ev.type == JS_EVENT_BUTTON) { int s = (btns >> ev.number) & 1; @@ -154,7 +154,7 @@ int mp_input_joystick_read(void *ctx, int fd) { } else return MP_INPUT_NOTHING; } else { - mp_tmsg(MSGT_INPUT,MSGL_WARN,MSGTR_INPUT_JOYSTICK_WarnUnknownEvent,ev.type); + mp_tmsg(MSGT_INPUT,MSGL_WARN,"Joystick warning unknown event type %d\n",ev.type); return MP_INPUT_ERROR; } |