GNOME Bugzilla – Bug 663406
[0.11] gstpluginfeature: make most of this structure private
Last modified: 2012-06-26 15:24:12 UTC
Also add consts. Some code was poking at 'loaded', so I added a _set_loaded routine, but it doesn't feel right. Better ideas welcome...
Created attachment 200693 [details] [review] gstpluginfeature: make most of this structure private
Thanks for working on this. Only had a quick glance, but my first impression is that not all functions should be public. IMHO external code doesn't really have any reason to create a plugin feature object, or set the loaded state, or set the plugin name, so these look like they should be private functions IMHO: +void gst_plugin_feature_set_loaded (GstPluginFeature * feature); +void gst_plugin_feature_set_plugin_name (const GstPluginFeature * feature, const gchar *); +void gst_plugin_feature_setup (GstPluginFeature * feature, + const gchar * name, GstPlugin * plugin, + guint rank, gboolean set_loaded);
Indeed. Rather dumbly, I hadn't realized there were non installed headers allowing a kind of inter-module private API. I'll move those there. Though _set_loaded still feels iffy, even if private.
Created attachment 201014 [details] [review] gstpluginfeature: make most of this structure private
Not doable in 0.10 but would be nice for 0.11. Do you want to update the patch for 0.11?
I'm currently messing around with the registry stuff, will have a look at this when done.
Thanks. It was done on 0.11 in fact, though it probably bitrotted by now.
I actually made the entire struct private a while back, which was easier and less intrusive (and I wasn't sure about some things and wanted to defer deciding on them).