From a446e560469e1c071d8bbbc2e8805c3328fbb1c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Tue, 11 Dec 2007 13:02:57 +0100 Subject: Update all combined plugins to the new identifier/description interface. Add _() where missing, for i18n. --- src/combined/flac_decoder.c | 12 ++---------- src/combined/flac_demuxer.c | 14 ++------------ src/combined/nsf_decoder.c | 16 ++-------------- src/combined/nsf_demuxer.c | 12 ++---------- src/combined/wavpack_decoder.c | 12 ++---------- src/combined/wavpack_demuxer.c | 12 ++---------- src/combined/xine_ogg_demuxer.c | 24 ++++-------------------- src/combined/xine_speex_decoder.c | 12 ++---------- src/combined/xine_theora_decoder.c | 20 ++------------------ src/combined/xine_vorbis_decoder.c | 12 ++---------- 10 files changed, 22 insertions(+), 124 deletions(-) (limited to 'src') diff --git a/src/combined/flac_decoder.c b/src/combined/flac_decoder.c index 75465f6fe..80d16903f 100644 --- a/src/combined/flac_decoder.c +++ b/src/combined/flac_decoder.c @@ -380,14 +380,6 @@ open_plugin (audio_decoder_class_t *class_gen, xine_stream_t *stream) { * flac plugin class */ -static char *get_identifier (audio_decoder_class_t *this) { - return "flacdec"; -} - -static char *get_description (audio_decoder_class_t *this) { - return "flac audio decoder plugin"; -} - static void dispose_class (audio_decoder_class_t *this) { free (this); } @@ -399,8 +391,8 @@ init_plugin (xine_t *xine, void *data) { this = (flac_class_t *) xine_xmalloc (sizeof (flac_class_t)); this->decoder_class.open_plugin = open_plugin; - this->decoder_class.get_identifier = get_identifier; - this->decoder_class.get_description = get_description; + this->decoder_class.identifier = "flacdec"; + this->decoder_class.description = _("flac audio decoder plugin"); this->decoder_class.dispose = dispose_class; diff --git a/src/combined/flac_demuxer.c b/src/combined/flac_demuxer.c index 7a5aabe0b..e4ac98258 100644 --- a/src/combined/flac_demuxer.c +++ b/src/combined/flac_demuxer.c @@ -713,16 +713,6 @@ open_plugin (demux_class_t *class_gen, /* FLAC Demuxer class */ -static char * -get_description (demux_class_t *this_gen) { - return "FLAC demux plugin"; -} - -static char * -get_identifier (demux_class_t *this_gen) { - return "FLAC"; -} - static char * get_extensions (demux_class_t *this_gen) { return "flac"; @@ -754,8 +744,8 @@ demux_flac_init_class (xine_t *xine, void *data) { this->xine = xine; this->demux_class.open_plugin = open_plugin; - this->demux_class.get_description = get_description; - this->demux_class.get_identifier = get_identifier; + this->demux_class.description = _("FLAC demux plugin"); + this->demux_class.identifier = "FLAC"; this->demux_class.get_mimetypes = get_mimetypes; this->demux_class.get_extensions = get_extensions; this->demux_class.dispose = class_dispose; diff --git a/src/combined/nsf_decoder.c b/src/combined/nsf_decoder.c index a809ff9cc..ea03138c1 100644 --- a/src/combined/nsf_decoder.c +++ b/src/combined/nsf_decoder.c @@ -230,18 +230,6 @@ static audio_decoder_t *open_plugin (audio_decoder_class_t *class_gen, xine_stre return &this->audio_decoder; } -/* This function returns a brief string that describes (usually with the - * decoder's most basic name) the audio decoder plugin. */ -static char *get_identifier (audio_decoder_class_t *this) { - return "NSF"; -} - -/* This function returns a slightly longer string describing the audio - * decoder plugin. */ -static char *get_description (audio_decoder_class_t *this) { - return "NES Music audio decoder plugin"; -} - /* This function frees the audio decoder class and any other memory that was * allocated. */ static void dispose_class (audio_decoder_class_t *this_gen) { @@ -260,8 +248,8 @@ void *decoder_nsf_init_plugin (xine_t *xine, void *data) { this = (nsf_class_t *) xine_xmalloc (sizeof (nsf_class_t)); this->decoder_class.open_plugin = open_plugin; - this->decoder_class.get_identifier = get_identifier; - this->decoder_class.get_description = get_description; + this->decoder_class.identifier = "NSF"; + this->decoder_class.description = _("NES Music audio decoder plugin"); this->decoder_class.dispose = dispose_class; return this; diff --git a/src/combined/nsf_demuxer.c b/src/combined/nsf_demuxer.c index 95897e3ac..63658eeef 100644 --- a/src/combined/nsf_demuxer.c +++ b/src/combined/nsf_demuxer.c @@ -349,14 +349,6 @@ static demux_plugin_t *open_plugin (demux_class_t *class_gen, xine_stream_t *str return &this->demux_plugin; } -static const char *get_description (demux_class_t *this_gen) { - return "NES Music file demux plugin"; -} - -static const char *get_identifier (demux_class_t *this_gen) { - return "NSF"; -} - static const char *get_extensions (demux_class_t *this_gen) { return "nsf"; } @@ -377,8 +369,8 @@ void *demux_nsf_init_plugin (xine_t *xine, void *data) { this = xine_xmalloc (sizeof (demux_nsf_class_t)); this->demux_class.open_plugin = open_plugin; - this->demux_class.get_description = get_description; - this->demux_class.get_identifier = get_identifier; + this->demux_class.description = _("NES Music file demux plugin"); + this->demux_class.identifier = "NSF"; this->demux_class.get_mimetypes = get_mimetypes; this->demux_class.get_extensions = get_extensions; this->demux_class.dispose = class_dispose; diff --git a/src/combined/wavpack_decoder.c b/src/combined/wavpack_decoder.c index 2bd0339d8..f1201bbcd 100644 --- a/src/combined/wavpack_decoder.c +++ b/src/combined/wavpack_decoder.c @@ -311,14 +311,6 @@ static audio_decoder_t *open_plugin (audio_decoder_class_t *class_gen, xine_stre * wavpack plugin class */ -static char *get_identifier (audio_decoder_class_t *this) { - return "wavpackdec"; -} - -static char *get_description (audio_decoder_class_t *this) { - return "wavpack audio decoder plugin"; -} - static void dispose_class (audio_decoder_class_t *this) { free (this); } @@ -329,8 +321,8 @@ void *decoder_wavpack_init_plugin (xine_t *xine, void *data) { this = (wavpack_class_t *) xine_xmalloc (sizeof (wavpack_class_t)); this->decoder_class.open_plugin = open_plugin; - this->decoder_class.get_identifier = get_identifier; - this->decoder_class.get_description = get_description; + this->decoder_class.identifier = "wavpackdec"; + this->decoder_class.description = _("wavpack audio decoder plugin"); this->decoder_class.dispose = dispose_class; return this; diff --git a/src/combined/wavpack_demuxer.c b/src/combined/wavpack_demuxer.c index 4b8300d44..a3f217703 100644 --- a/src/combined/wavpack_demuxer.c +++ b/src/combined/wavpack_demuxer.c @@ -378,14 +378,6 @@ static demux_plugin_t *open_plugin (demux_class_t *const class_gen, return &this->demux_plugin; } -static const char *get_description (demux_class_t *const this_gen) { - return "Wavpack demux plugin"; -} - -static const char *get_identifier (demux_class_t *const this_gen) { - return "Wavpack"; -} - static const char *get_extensions (demux_class_t *const this_gen) { return "wv"; } @@ -404,8 +396,8 @@ void *demux_wv_init_plugin (xine_t *const xine, void *const data) { demux_wv_class_t *const this = xine_xmalloc (sizeof (demux_wv_class_t)); this->demux_class.open_plugin = open_plugin; - this->demux_class.get_description = get_description; - this->demux_class.get_identifier = get_identifier; + this->demux_class.description = _("Wavpack demux plugin"); + this->demux_class.identifier = "Wavpack"; this->demux_class.get_mimetypes = get_mimetypes; this->demux_class.get_extensions = get_extensions; this->demux_class.dispose = class_dispose; diff --git a/src/combined/xine_ogg_demuxer.c b/src/combined/xine_ogg_demuxer.c index 2a69c4da2..5d10e3926 100644 --- a/src/combined/xine_ogg_demuxer.c +++ b/src/combined/xine_ogg_demuxer.c @@ -2117,14 +2117,6 @@ static demux_plugin_t *ogg_open_plugin (demux_class_t *class_gen, * Annodex demuxer class */ -static const char *anx_get_description (demux_class_t *this_gen) { - return "Annodex demux plugin"; -} - -static const char *anx_get_identifier (demux_class_t *this_gen) { - return "Annodex"; -} - static const char *anx_get_extensions (demux_class_t *this_gen) { return "anx axa axv"; } @@ -2145,8 +2137,8 @@ static void *anx_init_class (xine_t *xine, void *data) { this = xine_xmalloc (sizeof (demux_anx_class_t)); this->demux_class.open_plugin = anx_open_plugin; - this->demux_class.get_description = anx_get_description; - this->demux_class.get_identifier = anx_get_identifier; + this->demux_class.description = _("Annodex demux plugin"); + this->demux_class.identifier = "Annodex"; this->demux_class.get_mimetypes = anx_get_mimetypes; this->demux_class.get_extensions = anx_get_extensions; this->demux_class.dispose = anx_class_dispose; @@ -2158,14 +2150,6 @@ static void *anx_init_class (xine_t *xine, void *data) { * ogg demuxer class */ -static const char *ogg_get_description (demux_class_t *this_gen) { - return "OGG demux plugin"; -} - -static const char *ogg_get_identifier (demux_class_t *this_gen) { - return "OGG"; -} - static const char *ogg_get_extensions (demux_class_t *this_gen) { return "ogg ogm spx"; } @@ -2189,8 +2173,8 @@ static void *ogg_init_class (xine_t *xine, void *data) { this = xine_xmalloc (sizeof (demux_ogg_class_t)); this->demux_class.open_plugin = ogg_open_plugin; - this->demux_class.get_description = ogg_get_description; - this->demux_class.get_identifier = ogg_get_identifier; + this->demux_class.description = _("OGG demux plugin"); + this->demux_class.identifier = "OGG"; this->demux_class.get_mimetypes = ogg_get_mimetypes; this->demux_class.get_extensions = ogg_get_extensions; this->demux_class.dispose = ogg_class_dispose; diff --git a/src/combined/xine_speex_decoder.c b/src/combined/xine_speex_decoder.c index fa1ede0f2..ee93c520d 100644 --- a/src/combined/xine_speex_decoder.c +++ b/src/combined/xine_speex_decoder.c @@ -376,14 +376,6 @@ static audio_decoder_t *open_plugin (audio_decoder_class_t *class_gen, * speex plugin class */ -static char *get_identifier (audio_decoder_class_t *this) { - return "speex"; -} - -static char *get_description (audio_decoder_class_t *this) { - return "Speex audio decoder plugin"; -} - static void dispose_class (audio_decoder_class_t *this) { free (this); } @@ -395,8 +387,8 @@ void *speex_init_plugin (xine_t *xine, void *data) { this = (speex_class_t *) xine_xmalloc (sizeof (speex_class_t)); this->decoder_class.open_plugin = open_plugin; - this->decoder_class.get_identifier = get_identifier; - this->decoder_class.get_description = get_description; + this->decoder_class.identifier = "speex"; + this->decoder_class.description = _("Speex audio decoder plugin"); this->decoder_class.dispose = dispose_class; return this; diff --git a/src/combined/xine_theora_decoder.c b/src/combined/xine_theora_decoder.c index 9fd3d6416..e7d59624a 100644 --- a/src/combined/xine_theora_decoder.c +++ b/src/combined/xine_theora_decoder.c @@ -343,22 +343,6 @@ static video_decoder_t *theora_open_plugin (video_decoder_class_t *class_gen, xi /* * theora plugin class */ - -static char *theora_get_identifier (video_decoder_class_t *this) { - /* - * return short, human readable identifier for this plugin class - */ - return "theora video"; -} - -static char *theora_get_description (video_decoder_class_t *this) { - /* - * return human readable (verbose = 1 line) description for - * this plugin class - */ - return "theora video decoder plugin"; -} - static void theora_dispose_class (video_decoder_class_t *this) { /* * free all class-related resources @@ -373,8 +357,8 @@ void *theora_init_plugin (xine_t *xine, void *data) { this = (theora_class_t *) xine_xmalloc (sizeof (theora_class_t)); this->decoder_class.open_plugin = theora_open_plugin; - this->decoder_class.get_identifier = theora_get_identifier; - this->decoder_class.get_description = theora_get_description; + this->decoder_class.identifier = "theora video"; + this->decoder_class.description = _("theora video decoder plugin"); this->decoder_class.dispose = theora_dispose_class; return this; diff --git a/src/combined/xine_vorbis_decoder.c b/src/combined/xine_vorbis_decoder.c index 29d095228..5409ba935 100644 --- a/src/combined/xine_vorbis_decoder.c +++ b/src/combined/xine_vorbis_decoder.c @@ -311,14 +311,6 @@ static audio_decoder_t *open_plugin (audio_decoder_class_t *class_gen, * vorbis plugin class */ -static char *get_identifier (audio_decoder_class_t *this) { - return "vorbis"; -} - -static char *get_description (audio_decoder_class_t *this) { - return "vorbis audio decoder plugin"; -} - static void dispose_class (audio_decoder_class_t *this) { free (this); } @@ -330,8 +322,8 @@ void *vorbis_init_plugin (xine_t *xine, void *data) { this = (vorbis_class_t *) xine_xmalloc (sizeof (vorbis_class_t)); this->decoder_class.open_plugin = open_plugin; - this->decoder_class.get_identifier = get_identifier; - this->decoder_class.get_description = get_description; + this->decoder_class.identifier = "vorbis"; + this->decoder_class.description = _("vorbis audio decoder plugin"); this->decoder_class.dispose = dispose_class; return this; -- cgit v1.2.3