summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUoti Urpala <uau@glyph.nonexistent.invalid>2010-03-07 19:25:52 +0200
committerUoti Urpala <uau@glyph.nonexistent.invalid>2010-03-07 21:35:23 +0200
commitb34a88e4f44ee2a926c8c30f8fb3954fc7d71b90 (patch)
treecb056d99378f7a00fb64f4ddd2598f50938f8833
parent5234c72e28c27e232a35ebcbadc50c5933cccf7d (diff)
downloadmpv-b34a88e4f44ee2a926c8c30f8fb3954fc7d71b90.tar.bz2
mpv-b34a88e4f44ee2a926c8c30f8fb3954fc7d71b90.tar.xz
translations: tweak cases that relied on concatenating adjacent strings
Tweak some code parts that used to rely on string literals from translation macros being concatenated with other adjacent string literals. Break up the resulting string into independently translated parts, so that the existing translations for those parts can still be used.
-rw-r--r--libaf/af_scaletempo.c32
-rw-r--r--libmpcodecs/vf.c11
-rw-r--r--libmpdemux/demux_asf.c6
-rw-r--r--libmpdemux/demux_avi.c10
-rw-r--r--libmpdemux/demux_lmlm4.c6
-rw-r--r--libmpdemux/demux_mpg.c6
-rw-r--r--libmpdemux/demux_real.c6
-rw-r--r--libmpdemux/demux_ty.c3
-rw-r--r--libmpdemux/demux_viv.c6
-rw-r--r--libmpdemux/muxer_rawaudio.c3
-rw-r--r--mplayer.c7
-rw-r--r--stream/stream_cue.c3
-rw-r--r--stream/stream_vcd.c6
13 files changed, 64 insertions, 41 deletions
diff --git a/libaf/af_scaletempo.c b/libaf/af_scaletempo.c
index 6534a124ec..4c86744231 100644
--- a/libaf/af_scaletempo.c
+++ b/libaf/af_scaletempo.c
@@ -471,27 +471,28 @@ static int control(struct af_instance_s* af, int cmd, void* arg)
return AF_ERROR;
}
if (s->scale_nominal <= 0) {
- mp_tmsg(MSGT_AFILTER, MSGL_ERR, "[scaletempo] "
- _("error parsing command line") ": " _("value out of range")
- ": scale > 0\n");
+ mp_msg(MSGT_AFILTER, MSGL_ERR, "[scaletempo] %s: %s: scale > 0\n",
+ mp_gtext("error parsing command line"),
+ mp_gtext("value out of range"));
return AF_ERROR;
}
if (s->ms_stride <= 0) {
- mp_tmsg(MSGT_AFILTER, MSGL_ERR, "[scaletempo] "
- _("error parsing command line") ": " _("value out of range")
- ": stride > 0\n");
+ mp_msg(MSGT_AFILTER, MSGL_ERR, "[scaletempo] %s: %s: stride > 0\n",
+ mp_gtext("error parsing command line"),
+ mp_gtext("value out of range"));
return AF_ERROR;
}
if (s->percent_overlap < 0 || s->percent_overlap > 1) {
- mp_tmsg(MSGT_AFILTER, MSGL_ERR, "[scaletempo] "
- _("error parsing command line") ": " _("value out of range")
- ": 0 <= overlap <= 1\n");
+ mp_msg(MSGT_AFILTER, MSGL_ERR,
+ "[scaletempo] %s: %s: 0 <= overlap <= 1\n",
+ mp_gtext("error parsing command line"),
+ mp_gtext("value out of range"));
return AF_ERROR;
}
if (s->ms_search < 0) {
- mp_tmsg(MSGT_AFILTER, MSGL_ERR, "[scaletempo] "
- _("error parsing command line") ": " _("value out of range")
- ": search >= 0\n");
+ mp_msg(MSGT_AFILTER, MSGL_ERR, "[scaletempo] %s: %s: search >= 0\n",
+ mp_gtext("error parsing command line"),
+ mp_gtext("value out of range"));
return AF_ERROR;
}
if (speed.len > 0) {
@@ -508,9 +509,10 @@ static int control(struct af_instance_s* af, int cmd, void* arg)
s->speed_tempo = 1;
s->speed_pitch = 1;
} else {
- mp_tmsg(MSGT_AFILTER, MSGL_ERR, "[scaletempo] "
- _("error parsing command line") ": " _("value out of range")
- ": speed=[pitch|tempo|none|both]\n");
+ mp_msg(MSGT_AFILTER, MSGL_ERR,
+ "[scaletempo] %s: %s: speed=[pitch|tempo|none|both]\n",
+ mp_gtext("error parsing command line"),
+ mp_gtext("value out of range"));
return AF_ERROR;
}
}
diff --git a/libmpcodecs/vf.c b/libmpcodecs/vf.c
index c6f23eb382..682480f85b 100644
--- a/libmpcodecs/vf.c
+++ b/libmpcodecs/vf.c
@@ -489,15 +489,16 @@ vf_instance_t* vf_open_filter(struct MPOpts *opts, vf_instance_t* next, const ch
p += sprintf(str,"%s",name);
for(i = 0 ; args && args[2*i] ; i++)
p += sprintf(p," %s=%s",args[2*i],args[2*i+1]);
- mp_tmsg(MSGT_VFILTER,MSGL_INFO,"Opening video filter: " "[%s]\n",str);
+ mp_msg(MSGT_VFILTER, MSGL_INFO, "%s[%s]\n",
+ mp_gtext("Opening video filter: "), str);
}
} else if(strcmp(name,"vo")) {
if(args && strcmp(args[0],"_oldargs_") == 0)
- mp_tmsg(MSGT_VFILTER,MSGL_INFO,"Opening video filter: "
- "[%s=%s]\n", name,args[1]);
+ mp_msg(MSGT_VFILTER, MSGL_INFO, "%s[%s=%s]\n",
+ mp_gtext("Opening video filter: "), name, args[1]);
else
- mp_tmsg(MSGT_VFILTER,MSGL_INFO,"Opening video filter: "
- "[%s]\n", name);
+ mp_msg(MSGT_VFILTER, MSGL_INFO, "%s[%s]\n",
+ mp_gtext("Opening video filter: "), name);
}
return vf_open_plugin(opts, filter_list,next,name,args);
}
diff --git a/libmpdemux/demux_asf.c b/libmpdemux/demux_asf.c
index e205524d62..4d7490e7f8 100644
--- a/libmpdemux/demux_asf.c
+++ b/libmpdemux/demux_asf.c
@@ -642,7 +642,8 @@ static demuxer_t* demux_open_asf(demuxer_t* demuxer)
// demuxer->endpos=avi_header.movi_end;
if(demuxer->video->id != -2) {
if(!ds_fill_buffer(demuxer->video)){
- mp_tmsg(MSGT_DEMUXER,MSGL_WARN,"ASF: " "No video stream found.\n");
+ mp_msg(MSGT_DEMUXER, MSGL_WARN, "ASF: %s",
+ mp_gtext("No video stream found.\n"));
demuxer->video->sh=NULL;
//printf("ASF: missing video stream!? contact the author, it may be a bug :(\n");
} else {
@@ -659,7 +660,8 @@ static demuxer_t* demux_open_asf(demuxer_t* demuxer)
if(demuxer->audio->id!=-2){
mp_tmsg(MSGT_DEMUXER,MSGL_V,"ASF: Searching for audio stream (id:%d).\n",demuxer->audio->id);
if(!ds_fill_buffer(demuxer->audio)){
- mp_tmsg(MSGT_DEMUXER,MSGL_INFO,"ASF: " "No audio stream found -> no sound.\n");
+ mp_msg(MSGT_DEMUXER, MSGL_INFO, "ASF: %s",
+ mp_gtext("No audio stream found -> no sound.\n"));
demuxer->audio->sh=NULL;
} else {
sh_audio=demuxer->audio->sh;sh_audio->ds=demuxer->audio;
diff --git a/libmpdemux/demux_avi.c b/libmpdemux/demux_avi.c
index 6671b0c322..12b04b3e01 100644
--- a/libmpdemux/demux_avi.c
+++ b/libmpdemux/demux_avi.c
@@ -492,7 +492,8 @@ static demuxer_t* demux_open_avi(demuxer_t* demuxer){
}
}
if(v_pos==-1){
- mp_tmsg(MSGT_DEMUX,MSGL_ERR,"AVI_NI: " "No video stream found.\n");
+ mp_msg(MSGT_DEMUX, MSGL_ERR, "AVI_NI: %s",
+ mp_gtext("No video stream found.\n"));
return NULL;
}
if(a_pos==-1){
@@ -518,14 +519,17 @@ static demuxer_t* demux_open_avi(demuxer_t* demuxer){
demuxer->seekable=0;
}
if(!ds_fill_buffer(d_video)){
- mp_tmsg(MSGT_DEMUX,MSGL_ERR,"AVI: " "Missing video stream!? Contact the author, it may be a bug :(\n");
+ mp_msg(MSGT_DEMUX, MSGL_ERR, "AVI: %s",
+ mp_gtext("Missing video stream!? Contact the author, "
+ "it may be a bug :(\n"));
return NULL;
}
sh_video=d_video->sh;sh_video->ds=d_video;
if(d_audio->id!=-2){
mp_msg(MSGT_DEMUX,MSGL_V,"AVI: Searching for audio stream (id:%d)\n",d_audio->id);
if(!priv->audio_streams || !ds_fill_buffer(d_audio)){
- mp_tmsg(MSGT_DEMUX,MSGL_INFO,"AVI: " "No audio stream found -> no sound.\n");
+ mp_msg(MSGT_DEMUX, MSGL_INFO, "AVI: %s",
+ mp_gtext("No audio stream found -> no sound.\n"));
d_audio->sh=sh_audio=NULL;
} else {
sh_audio=d_audio->sh;sh_audio->ds=d_audio;
diff --git a/libmpdemux/demux_lmlm4.c b/libmpdemux/demux_lmlm4.c
index c091fd1ba0..e221a5b893 100644
--- a/libmpdemux/demux_lmlm4.c
+++ b/libmpdemux/demux_lmlm4.c
@@ -344,14 +344,16 @@ static demuxer_t* demux_open_lmlm4(demuxer_t* demuxer){
demuxer->seekable = 0;
if(!ds_fill_buffer(demuxer->video)){
- mp_tmsg(MSGT_DEMUXER,MSGL_INFO,"LMLM4: " "No video stream found.\n");
+ mp_msg(MSGT_DEMUXER, MSGL_INFO, "LMLM4: %s",
+ mp_gtext("No video stream found.\n"));
demuxer->video->sh=NULL;
} else {
sh_video=demuxer->video->sh;sh_video->ds=demuxer->video;
}
if(demuxer->audio->id!=-2) {
if(!ds_fill_buffer(demuxer->audio)){
- mp_tmsg(MSGT_DEMUXER,MSGL_INFO,"LMLM4: " "No audio stream found -> no sound.\n");
+ mp_msg(MSGT_DEMUXER, MSGL_INFO, "LMLM4: %s",
+ mp_gtext("No audio stream found -> no sound.\n"));
demuxer->audio->sh=NULL;
} else {
sh_audio=demuxer->audio->sh;sh_audio->ds=demuxer->audio;
diff --git a/libmpdemux/demux_mpg.c b/libmpdemux/demux_mpg.c
index 8f6220be8f..1e994afa41 100644
--- a/libmpdemux/demux_mpg.c
+++ b/libmpdemux/demux_mpg.c
@@ -726,7 +726,8 @@ static int demux_mpg_probe(demuxer_t *demuxer) {
} else
{
if(demuxer->synced==2)
- mp_tmsg(MSGT_DEMUXER,MSGL_ERR,"MPEG: " "Missing video stream!? Contact the author, it may be a bug :(\n");
+ mp_msg(MSGT_DEMUXER, MSGL_ERR, "MPEG: %s",
+ mp_gtext("Missing video stream!? Contact the author, it may be a bug :(\n"));
else
mp_tmsg(MSGT_DEMUXER,MSGL_V,"Not MPEG System Stream format... (maybe Transport Stream?)\n");
}
@@ -1102,7 +1103,8 @@ static demuxer_t* demux_mpg_ps_open(demuxer_t* demuxer)
if(demuxer->audio->id!=-2) {
if(!ds_fill_buffer(demuxer->audio)){
- mp_tmsg(MSGT_DEMUXER,MSGL_INFO,"MPEG: " "No audio stream found -> no sound.\n");
+ mp_msg(MSGT_DEMUXER, MSGL_INFO, "MPEG: %s",
+ mp_gtext("No audio stream found -> no sound.\n"));
demuxer->audio->sh=NULL;
} else {
sh_audio=demuxer->audio->sh;sh_audio->ds=demuxer->audio;
diff --git a/libmpdemux/demux_real.c b/libmpdemux/demux_real.c
index f6611eb2ed..8f3a46d56c 100644
--- a/libmpdemux/demux_real.c
+++ b/libmpdemux/demux_real.c
@@ -1740,13 +1740,15 @@ header_end:
if(demuxer->video->id==-1 && v_streams>0){
// find the valid video stream:
if(!ds_fill_buffer(demuxer->video)){
- mp_tmsg(MSGT_DEMUXER,MSGL_INFO,"RM: " "No video stream found.\n");
+ mp_msg(MSGT_DEMUXER, MSGL_INFO, "RM: %s",
+ mp_gtext("No video stream found.\n"));
}
}
if(demuxer->audio->id==-1 && a_streams>0){
// find the valid audio stream:
if(!ds_fill_buffer(demuxer->audio)){
- mp_tmsg(MSGT_DEMUXER,MSGL_INFO,"RM: " "No audio stream found -> no sound.\n");
+ mp_msg(MSGT_DEMUXER, MSGL_INFO, "RM: %s",
+ mp_gtext("No audio stream found -> no sound.\n"));
}
}
diff --git a/libmpdemux/demux_ty.c b/libmpdemux/demux_ty.c
index 9515d0b893..5f6dcdb59a 100644
--- a/libmpdemux/demux_ty.c
+++ b/libmpdemux/demux_ty.c
@@ -871,7 +871,8 @@ static demuxer_t* demux_open_ty(demuxer_t* demuxer)
if(demuxer->audio->id!=-2) {
if(!ds_fill_buffer(demuxer->audio)){
- mp_tmsg(MSGT_DEMUXER,MSGL_INFO,"MPEG: " "No audio stream found -> no sound.\n");
+ mp_msg(MSGT_DEMUXER, MSGL_INFO, "MPEG: %s",
+ mp_gtext("No audio stream found -> no sound.\n"));
demuxer->audio->sh=NULL;
} else {
sh_audio=demuxer->audio->sh;sh_audio->ds=demuxer->audio;
diff --git a/libmpdemux/demux_viv.c b/libmpdemux/demux_viv.c
index d0a2615d42..77e6200dac 100644
--- a/libmpdemux/demux_viv.c
+++ b/libmpdemux/demux_viv.c
@@ -562,7 +562,8 @@ static demuxer_t* demux_open_vivo(demuxer_t* demuxer){
vivo_priv_t* priv=demuxer->priv;
if(!ds_fill_buffer(demuxer->video)){
- mp_tmsg(MSGT_DEMUX,MSGL_ERR,"VIVO: " "Missing video stream!? Contact the author, it may be a bug :(\n");
+ mp_msg(MSGT_DEMUX, MSGL_ERR, "VIVO: %s",
+ mp_gtext("Missing video stream!? Contact the author, it may be a bug :(\n"));
return NULL;
}
@@ -645,7 +646,8 @@ static demuxer_t* demux_open_vivo(demuxer_t* demuxer){
/* AUDIO init */
if (demuxer->audio->id >= -1){
if(!ds_fill_buffer(demuxer->audio)){
- mp_tmsg(MSGT_DEMUX,MSGL_ERR,"VIVO: " "No audio stream found -> no sound.\n");
+ mp_msg(MSGT_DEMUX, MSGL_ERR, "VIVO: %s",
+ mp_gtext("No audio stream found -> no sound.\n"));
} else
{ sh_audio_t* sh=new_sh_audio(demuxer,1);
diff --git a/libmpdemux/muxer_rawaudio.c b/libmpdemux/muxer_rawaudio.c
index 341999ee1d..24cef1c562 100644
--- a/libmpdemux/muxer_rawaudio.c
+++ b/libmpdemux/muxer_rawaudio.c
@@ -34,7 +34,8 @@ static muxer_stream_t* rawaudiofile_new_stream(muxer_t *muxer,int type){
muxer_stream_t* s;
if (!muxer) return NULL;
if(type==MUXER_TYPE_AUDIO && muxer->avih.dwStreams>=1){
- mp_tmsg(MSGT_MUXER,MSGL_ERR,"Too many streams!"" ""Rawaudio muxer supports only one audio stream!\n");
+ mp_msg(MSGT_MUXER, MSGL_ERR, "%s %s", mp_gtext("Too many streams!"),
+ mp_gtext("Rawaudio muxer supports only one audio stream!\n"));
return NULL;
}
s=malloc(sizeof(muxer_stream_t));
diff --git a/mplayer.c b/mplayer.c
index ed8bf4da83..b13192496a 100644
--- a/mplayer.c
+++ b/mplayer.c
@@ -820,9 +820,10 @@ static void exit_sighandler(int x){
kill(getpid(),SIGKILL);
#endif
}
- mp_tmsg(MSGT_CPLAYER,MSGL_FATAL,"\n" "\nMPlayer interrupted by signal %d in module: %s\n",x,
- current_module?current_module:"unknown"
- );
+ mp_msg(MSGT_CPLAYER, MSGL_FATAL, "\n");
+ mp_tmsg(MSGT_CPLAYER,MSGL_FATAL,
+ "\nMPlayer interrupted by signal %d in module: %s\n", x,
+ current_module ? current_module : "unknown");
mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_SIGNAL=%d\n", x);
if(sig_count<=1)
switch(x){
diff --git a/stream/stream_cue.c b/stream/stream_cue.c
index 33b8e84764..fe36b22d51 100644
--- a/stream/stream_cue.c
+++ b/stream/stream_cue.c
@@ -570,7 +570,8 @@ static int open_s(stream_t *stream,int mode, void* opts, int* file_format) {
ret2=cue_vcd_get_track_end(track);
ret=cue_vcd_seek_to_track(track);
if(ret<0){
- mp_tmsg(MSGT_OPEN,MSGL_ERR,"Error selecting VCD track." " (seek)\n");
+ mp_msg(MSGT_OPEN, MSGL_ERR, "%s (seek)\n",
+ mp_gtext("Error selecting VCD track."));
return STREAM_UNSUPPORTED;
}
mp_tmsg(MSGT_OPEN,MSGL_INFO,"CUE stream_open, filename=%s, track=%d, available tracks: %d -> %d\n", filename, track, ret, ret2);
diff --git a/stream/stream_vcd.c b/stream/stream_vcd.c
index 324075d16f..a7f77e193b 100644
--- a/stream/stream_vcd.c
+++ b/stream/stream_vcd.c
@@ -126,7 +126,8 @@ static int open_s(stream_t *stream,int mode, void* opts, int* file_format) {
}
ret2=vcd_get_track_end(vcd,p->track);
if(ret2<0){
- mp_tmsg(MSGT_OPEN,MSGL_ERR,"Error selecting VCD track." " (get)\n");
+ mp_msg(MSGT_OPEN, MSGL_ERR, "%s (get)\n",
+ mp_gtext("Error selecting VCD track."));
close(f);
free(vcd);
m_struct_free(&stream_opts,opts);
@@ -134,7 +135,8 @@ static int open_s(stream_t *stream,int mode, void* opts, int* file_format) {
}
ret=vcd_seek_to_track(vcd,p->track);
if(ret<0){
- mp_tmsg(MSGT_OPEN,MSGL_ERR,"Error selecting VCD track." " (seek)\n");
+ mp_msg(MSGT_OPEN, MSGL_ERR, "%s (seek)\n",
+ mp_gtext("Error selecting VCD track."));
close(f);
free(vcd);
m_struct_free(&stream_opts,opts);