GNOME Bugzilla – Bug 683760
Formatter.can_load_uri cannot be used as a gtk filter function
Last modified: 2013-11-16 22:59:52 UTC
Using can_load_uri as a GtkFileFilterFunc, like so: default = Gtk.FileFilter() default.set_name(_("All formats")) default.add_custom(Gtk.FileFilterFlags.URI, GES.Formatter.can_load_uri, None) chooser.add_filter(default) ...Gives a TypeError: can_load_uri() takes exactly 1 argument (2 given)
Ah, and the GTK documentation says that the GtkFileFilterFunc should have this signature: - filter_info: a GtkFileFilterInfo that is filled according to the needed flags passed to gtk_file_filter_add_custom() - data: user data passed to gtk_file_filter_add_custom(). [closure] And then the function would return TRUE if the file is considered supported by GES.
This is not a bug to me, you have to create a function that is usable for that use case, no one ever said that this method was a GtkFileFilterFunc, most probably because it is not :)