Commit 997621c9 authored by Tim-Philipp Müller's avatar Tim-Philipp Müller

gst/playback/: Better error message for text files.

Original commit message from CVS:
* gst/playback/gstdecodebin.c: (type_found), (plugin_init):
* gst/playback/gstdecodebin2.c: (plugin_init):
Better error message for text files.
parent 7033e458
2007-05-01 Tim-Philipp Müller <tim at centricular dot net>
* gst/playback/gstdecodebin.c: (type_found), (plugin_init):
* gst/playback/gstdecodebin2.c: (plugin_init):
Better error message for text files.
2007-04-29 Wim Taymans <wim@fluendo.com>
* gst-libs/gst/rtp/gstrtcpbuffer.c: (gst_rtcp_packet_add_rb):
......@@ -21,6 +21,8 @@
#include "config.h"
#endif
#include <gst/gst-i18n-plugin.h>
#include <string.h>
#include <gst/gst.h>
#include <gst/pbutils/pbutils.h>
......@@ -1545,7 +1547,8 @@ type_found (GstElement * typefind, guint probability, GstCaps * caps,
gst_structure_has_name (gst_caps_get_structure (caps, 0), "text/plain")) {
gst_element_no_more_pads (GST_ELEMENT (decode_bin));
/* we can't handle this type of stream */
GST_ELEMENT_ERROR (decode_bin, STREAM, WRONG_TYPE, (NULL),
GST_ELEMENT_ERROR (decode_bin, STREAM, WRONG_TYPE,
(_("This appears to be a text file")),
("decodebin cannot decode plain text files"));
goto shutting_down;
}
......@@ -1727,6 +1730,12 @@ plugin_init (GstPlugin * plugin)
{
GST_DEBUG_CATEGORY_INIT (gst_decode_bin_debug, "decodebin", 0, "decoder bin");
#ifdef ENABLE_NLS
GST_DEBUG ("binding text domain %s to locale dir %s", GETTEXT_PACKAGE,
LOCALEDIR);
bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
#endif /* ENABLE_NLS */
return gst_element_register (plugin, "decodebin", GST_RANK_NONE,
GST_TYPE_DECODE_BIN);
}
......
......@@ -36,6 +36,8 @@
#include "config.h"
#endif
#include <gst/gst-i18n-plugin.h>
#include <string.h>
#include <gst/gst.h>
#include <gst/pbutils/pbutils.h>
......@@ -2113,6 +2115,12 @@ plugin_init (GstPlugin * plugin)
GST_DEBUG_CATEGORY_INIT (gst_decode_bin_debug, "decodebin2", 0,
"decoder bin");
#ifdef ENABLE_NLS
GST_DEBUG ("binding text domain %s to locale dir %s", GETTEXT_PACKAGE,
LOCALEDIR);
bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
#endif /* ENABLE_NLS */
return gst_element_register (plugin, "decodebin2", GST_RANK_NONE,
GST_TYPE_DECODE_BIN);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment