From d549590467233ac74a0c04571b0bc59352e5be95 Mon Sep 17 00:00:00 2001 From: Edward Hervey Date: Tue, 12 Jun 2007 19:01:25 +0000 Subject: [PATCH] gst/__init__.py: Fix API cleanups that cause API breakage. Original commit message from CVS: * gst/__init__.py: Fix API cleanups that cause API breakage. Fixes #446674 --- ChangeLog | 6 ++++++ gst/__init__.py | 16 ++++++++++++++++ 2 files changed, 22 insertions(+) diff --git a/ChangeLog b/ChangeLog index 3376c19..c3c2c1b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2007-06-12 Edward Hervey + + * gst/__init__.py: + Fix API cleanups that cause API breakage. + Fixes #446674 + 2007-06-11 Jan Schmidt * gst/gstpad.override: diff --git a/gst/__init__.py b/gst/__init__.py index 4527bae..91a8ded 100644 --- a/gst/__init__.py +++ b/gst/__init__.py @@ -153,6 +153,22 @@ version = get_gst_version sys.setdlopenflags(dlsave) del sys +# Fixes for API cleanups that would cause an API breakage. +# See #446674 + +import warnings +if "parse_bin_from_description" in _gst.__dict__: + def gst_parse_bin_from_description(*args, **kwargs): + warnings.warn("gst_parse_bin_from_description() is deprecated, please use parse_bin_from_description instead", + DeprecationWarning) + return parse_bin_from_description(*args, **kwargs) + +if "message_new_buffering" in _gst.__dict__: + def gst_message_new_buffering(*args, **kwargs): + warnings.warn("gst_message_new_buffering() is deprecated, please use message_new_buffering() instead", + DeprecationWarning) + return message_new_buffering(*args, **kwargs) + # this restores previously installed importhooks, so we don't interfere # with other people's module importers # it also clears out the module completely as if it were never loaded, -- 2.7.4