mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-23 00:36:51 +00:00
pluginfeature: deprecate gst_plugin_feature_type_name_filter()
It's only used internally anyway and the helper struct has namespace issues. API: deprecated gst_plugin_feature_type_name_filter() API: deprecated GstTypeNameData
This commit is contained in:
parent
606c53fc94
commit
19b4c9c793
4 changed files with 35 additions and 0 deletions
|
@ -156,6 +156,16 @@ not_found:
|
|||
*
|
||||
* Returns: TRUE if equal.
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
typedef struct
|
||||
{
|
||||
const gchar *name;
|
||||
GType type;
|
||||
} GstTypeNameData;
|
||||
gboolean gst_plugin_feature_type_name_filter (GstPluginFeature * feature,
|
||||
GstTypeNameData * data);
|
||||
#endif
|
||||
gboolean
|
||||
gst_plugin_feature_type_name_filter (GstPluginFeature * feature,
|
||||
GstTypeNameData * data)
|
||||
|
@ -166,6 +176,7 @@ gst_plugin_feature_type_name_filter (GstPluginFeature * feature,
|
|||
(data->name == NULL
|
||||
|| !strcmp (data->name, GST_PLUGIN_FEATURE_NAME (feature))));
|
||||
}
|
||||
#endif /* GST_REMOVE_DEPRECATED */
|
||||
|
||||
/**
|
||||
* gst_plugin_feature_set_name:
|
||||
|
|
|
@ -105,10 +105,12 @@ struct _GstPluginFeatureClass {
|
|||
*
|
||||
* Structure used for filtering based on @name and @type.
|
||||
*/
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
typedef struct {
|
||||
const gchar *name;
|
||||
GType type;
|
||||
} GstTypeNameData;
|
||||
#endif
|
||||
|
||||
/**
|
||||
* GstPluginFeatureFilter:
|
||||
|
@ -130,8 +132,10 @@ GType gst_plugin_feature_get_type (void);
|
|||
GstPluginFeature *
|
||||
gst_plugin_feature_load (GstPluginFeature *feature);
|
||||
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
gboolean gst_plugin_feature_type_name_filter (GstPluginFeature *feature,
|
||||
GstTypeNameData *data);
|
||||
#endif
|
||||
|
||||
void gst_plugin_feature_set_rank (GstPluginFeature *feature, guint rank);
|
||||
void gst_plugin_feature_set_name (GstPluginFeature *feature, const gchar *name);
|
||||
|
|
|
@ -642,6 +642,24 @@ gst_registry_plugin_filter (GstRegistry * registry,
|
|||
return list;
|
||||
}
|
||||
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
typedef struct
|
||||
{
|
||||
const gchar *name;
|
||||
GType type;
|
||||
} GstTypeNameData;
|
||||
static gboolean
|
||||
gst_plugin_feature_type_name_filter (GstPluginFeature * feature,
|
||||
GstTypeNameData * data)
|
||||
{
|
||||
g_assert (GST_IS_PLUGIN_FEATURE (feature));
|
||||
|
||||
return ((data->type == 0 || data->type == G_OBJECT_TYPE (feature)) &&
|
||||
(data->name == NULL
|
||||
|| !strcmp (data->name, GST_PLUGIN_FEATURE_NAME (feature))));
|
||||
}
|
||||
#endif
|
||||
|
||||
/* returns TRUE if the list was changed
|
||||
*
|
||||
* Must be called with the object lock taken */
|
||||
|
|
|
@ -77,7 +77,9 @@ static GstCheckABIStruct list[] = {
|
|||
{"GstTypeFindFactoryClass", sizeof (GstTypeFindFactoryClass), 304},
|
||||
{"GstTypeFindFactory", sizeof (GstTypeFindFactory), 216},
|
||||
{"GstTypeFind", sizeof (GstTypeFind), 64},
|
||||
#if !defined(GST_DISABLE_DEPRECATED) && !defined(GST_REMOVE_DEPRECATED)
|
||||
{"GstTypeNameData", sizeof (GstTypeNameData), 16},
|
||||
#endif
|
||||
{"GstURIHandlerInterface", sizeof (GstURIHandlerInterface), 88},
|
||||
{"GstValueTable", sizeof (GstValueTable), 64},
|
||||
#if !defined(GST_DISABLE_LOADSAVE) && !defined(GST_DISABLE_DEPRECATED) && !defined(GST_REMOVE_DEPRECATED)
|
||||
|
|
Loading…
Reference in a new issue