1
0
Fork 0
mirror of https://github.com/davatorium/rofi.git synced 2024-11-11 13:50:48 -05:00

Added 'rofi/themes' to paths checked for theme files (#1001)

This commit is contained in:
Keith Collister 2019-08-04 20:04:26 +01:00 committed by Dave Davenport
parent eece00bad6
commit d9eb9f25a1

View file

@ -1035,8 +1035,18 @@ char *helper_get_theme_path ( const char *file )
else {
filename = g_strconcat ( file, ".rasi", NULL );
}
// Check config directory.
// Check config's themes directory.
const char *cpath = g_get_user_config_dir ();
if ( cpath ) {
char *themep = g_build_filename ( cpath, "rofi", "themes", filename, NULL );
g_debug ( "Opening theme, testing: %s\n", themep );
if ( themep && g_file_test ( themep, G_FILE_TEST_EXISTS ) ) {
g_free ( filename );
return themep;
}
g_free ( themep );
}
// Check config directory.
if ( cpath ) {
char *themep = g_build_filename ( cpath, "rofi", filename, NULL );
g_debug ( "Opening theme, testing: %s\n", themep );