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:
parent
eece00bad6
commit
d9eb9f25a1
1 changed files with 11 additions and 1 deletions
|
@ -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 );
|
||||
|
|
Loading…
Reference in a new issue