mirror of
https://github.com/yshui/picom.git
synced 2024-11-11 13:51:02 -05:00
Merge pull request #1171 from absolutelynothelix/corner-radius-rules-only
This commit is contained in:
commit
733113c691
1 changed files with 5 additions and 5 deletions
10
src/win.c
10
src/win.c
|
@ -1139,16 +1139,16 @@ static void win_determine_blur_background(session_t *ps, struct managed_win *w)
|
||||||
* Determine if a window should have rounded corners.
|
* Determine if a window should have rounded corners.
|
||||||
*/
|
*/
|
||||||
static void win_determine_rounded_corners(session_t *ps, struct managed_win *w) {
|
static void win_determine_rounded_corners(session_t *ps, struct managed_win *w) {
|
||||||
if (ps->o.corner_radius == 0) {
|
|
||||||
w->corner_radius = 0;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
void *radius_override = NULL;
|
void *radius_override = NULL;
|
||||||
if (c2_match(ps, w, ps->o.corner_radius_rules, &radius_override)) {
|
if (c2_match(ps, w, ps->o.corner_radius_rules, &radius_override)) {
|
||||||
log_debug("Matched corner rule! %d", w->corner_radius);
|
log_debug("Matched corner rule! %d", w->corner_radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (ps->o.corner_radius == 0 && !radius_override) {
|
||||||
|
w->corner_radius = 0;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
// Don't round full screen windows & excluded windows,
|
// Don't round full screen windows & excluded windows,
|
||||||
// unless we find a corner override in corner_radius_rules
|
// unless we find a corner override in corner_radius_rules
|
||||||
if (!radius_override && ((w && win_is_fullscreen(ps, w)) ||
|
if (!radius_override && ((w && win_is_fullscreen(ps, w)) ||
|
||||||
|
|
Loading…
Reference in a new issue