display swallows criteria in placeholder windows

This commit is contained in:
Michael Stapelberg
2013-12-15 11:25:58 +01:00
parent 3a4ad9b330
commit 076636a835
6 changed files with 46 additions and 11 deletions

View File

@ -47,7 +47,7 @@ bool match_is_empty(Match *match) {
match->application == NULL &&
match->class == NULL &&
match->instance == NULL &&
match->role == NULL &&
match->window_role == NULL &&
match->urgent == U_DONTCHECK &&
match->id == XCB_NONE &&
match->con_id == NULL &&
@ -75,7 +75,7 @@ void match_copy(Match *dest, Match *src) {
DUPLICATE_REGEX(application);
DUPLICATE_REGEX(class);
DUPLICATE_REGEX(instance);
DUPLICATE_REGEX(role);
DUPLICATE_REGEX(window_role);
}
/*
@ -121,9 +121,9 @@ bool match_matches_window(Match *match, i3Window *window) {
}
}
if (match->role != NULL) {
if (match->window_role != NULL) {
if (window->role != NULL &&
regex_matches(match->role, window->role)) {
regex_matches(match->window_role, window->role)) {
LOG("window_role matches (%s)\n", window->role);
} else {
return false;
@ -196,7 +196,7 @@ void match_free(Match *match) {
regex_free(match->class);
regex_free(match->instance);
regex_free(match->mark);
regex_free(match->role);
regex_free(match->window_role);
/* Second step: free the regex helper struct itself */
FREE(match->title);
@ -204,5 +204,5 @@ void match_free(Match *match) {
FREE(match->class);
FREE(match->instance);
FREE(match->mark);
FREE(match->role);
FREE(match->window_role);
}