2008-06-24 Emmanuele Bassi <ebassi@openedhand.com>

Bug 989 - Add a search path for clutter script assets

	* clutter/clutter-script.h:
	* clutter/clutter-script.c:
	(clutter_script_finalize),
	(clutter_script_add_search_paths),
	(clutter_script_lookup_filename): Add the ability to define multiple
	search paths inside ClutterScript and to look up a specific filename
	inside those search paths. This is useful to define a set of
	directories where the assets for a UI definition are and still
	reference those assets by their name instead of the full path. (989,
	based on a patch by Matthew Allum)

	* clutter/clutter-texture.c:
	(clutter_texture_set_custom_property): Use the newly added
	clutter_script_lookup_filename() function.
This commit is contained in:
Emmanuele Bassi
2008-06-24 16:47:43 +00:00
parent d4da3a3e2a
commit 5521867989
5 changed files with 156 additions and 23 deletions

View File

@ -145,6 +145,12 @@ void clutter_script_connect_signals_full (ClutterScript *script,
ClutterScriptConnectFunc func,
gpointer user_data);
void clutter_script_add_search_paths (ClutterScript *script,
const gchar * const paths[],
gsize n_paths);
gchar * clutter_script_lookup_filename (ClutterScript *script,
const gchar *filename) G_GNUC_MALLOC;
G_END_DECLS
#endif /* __CLUTTER_SCRIPT_H__ */