Mercurial > pidgin
changeset 32731:f2478fe32c79
Override the probe function in the conversation theme loader.
author | Elliott Sales de Andrade <qulogic@pidgin.im> |
---|---|
date | Sat, 03 Mar 2012 08:39:34 +0000 |
parents | f7be1e356a23 |
children | 97bf6c9ef9ab |
files | pidgin/gtkconv-theme-loader.c |
diffstat | 1 files changed, 14 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/pidgin/gtkconv-theme-loader.c Sat Mar 03 08:19:33 2012 +0000 +++ b/pidgin/gtkconv-theme-loader.c Sat Mar 03 08:39:34 2012 +0000 @@ -99,6 +99,19 @@ return info; } +static gboolean +pidgin_conv_loader_probe(const gchar *dir) +{ + gboolean result; + gchar *plist_file; + + plist_file = g_build_filename(dir, "Contents", "Info.plist", NULL); + result = g_file_test(plist_file, G_FILE_TEST_IS_REGULAR); + g_free(plist_file); + + return result; +} + static PurpleTheme * pidgin_conv_loader_build(const gchar *dir) { @@ -252,6 +265,7 @@ PurpleThemeLoaderClass *loader_klass = PURPLE_THEME_LOADER_CLASS(klass); loader_klass->purple_theme_loader_build = pidgin_conv_loader_build; + loader_klass->probe_directory = pidgin_conv_loader_probe; }