mirror of https://github.com/davatorium/rofi.git
If no filter specified, match everything with default matcher
This commit is contained in:
parent
6a01c9c9f8
commit
0a31175da5
|
@ -442,11 +442,13 @@ PangoAttrList *token_match_get_pango_attr ( ThemeHighlight th, GRegex **tokens,
|
||||||
|
|
||||||
int token_match ( GRegex * const *tokens, const char *input )
|
int token_match ( GRegex * const *tokens, const char *input )
|
||||||
{
|
{
|
||||||
int match = ( tokens != NULL );
|
int match = TRUE;
|
||||||
// Do a tokenized match.
|
// Do a tokenized match.
|
||||||
|
if ( tokens ) {
|
||||||
for ( int j = 0; match && tokens[j]; j++ ) {
|
for ( int j = 0; match && tokens[j]; j++ ) {
|
||||||
match = g_regex_match ( (const GRegex *) tokens[j], input, 0, NULL );
|
match = g_regex_match ( (const GRegex *) tokens[j], input, 0, NULL );
|
||||||
}
|
}
|
||||||
|
}
|
||||||
return match;
|
return match;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue