diff options
author | Johan Dahlin <jdahlin@async.com.br> | 2008-11-12 12:40:34 +0000 |
---|---|---|
committer | Johan Dahlin <johan@src.gnome.org> | 2008-11-12 12:40:34 +0000 |
commit | 9e7f04a87a798a881906b8d296ee927e27c25172 (patch) | |
tree | 2e1c0a51da3f322a45c6618b10f9cf597e63f0d3 | |
parent | 2cba8513200ead160203496570e5da9aba0ce9e1 (diff) | |
download | gobject-introspection-9e7f04a87a798a881906b8d296ee927e27c25172.tar.gz |
Add a g_irepository_get_search_path, so we can access the search paths
2008-11-12 Johan Dahlin <jdahlin@async.com.br>
* girepository/girepository.c (g_irepository_get_search_path):
* girepository/girepository.h:
Add a g_irepository_get_search_path, so we can access the search
paths from runtime.
svn path=/trunk/; revision=893
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | girepository/girepository.c | 15 | ||||
-rw-r--r-- | girepository/girepository.h | 1 |
3 files changed, 23 insertions, 0 deletions
@@ -1,3 +1,10 @@ +2008-11-12 Johan Dahlin <jdahlin@async.com.br> + + * girepository/girepository.c (g_irepository_get_search_path): + * girepository/girepository.h: + Add a g_irepository_get_search_path, so we can access the search + paths from runtime. + 2008-11-12 Johan Bilien <jobi@via.ecp.fr> Bug 560474 – g-ir-compiler crashes when compiling the glib gir diff --git a/girepository/girepository.c b/girepository/girepository.c index dc9473a8..392118d9 100644 --- a/girepository/girepository.c +++ b/girepository/girepository.c @@ -137,6 +137,21 @@ g_irepository_prepend_search_path (const char *directory) search_path = g_slist_prepend (search_path, g_strdup (directory)); } +/** + * g_irepository_get_search_path: + * + * Returns the search path the GIRepository will use when looking for typelibs. + * The string is internal to GIRespository and should not be freed, nor should + * the elements. + * + * Return value: (element-type utf8) (transfer none): list of strings + */ +GSList * +g_irepository_get_search_path (void) +{ + return search_path; +} + static char * build_typelib_key (const char *name, const char *source) { diff --git a/girepository/girepository.h b/girepository/girepository.h index c40b6b74..225c1f89 100644 --- a/girepository/girepository.h +++ b/girepository/girepository.h @@ -77,6 +77,7 @@ typedef enum GType g_irepository_get_type (void) G_GNUC_CONST; GIRepository *g_irepository_get_default (void); void g_irepository_prepend_search_path (const char *directory); +GSList * g_irepository_get_search_path (void); const char * g_irepository_load_typelib (GIRepository *repository, GTypelib *typelib, GIRepositoryLoadFlags flags, |