1
0
Fork 0
mirror of https://github.com/yshui/picom.git synced 2025-04-14 17:53:25 -04:00

config: fix use of the "geometry" alias in animation suppressions

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui 2024-11-14 15:25:53 +00:00
parent a017833228
commit 801553f1d5
No known key found for this signature in database
GPG key ID: D3A4405BE6CC17F4

View file

@ -423,6 +423,19 @@ static bool parse_animation_one(struct win_script *animations,
config_setting_remove(setting, "suppressions");
}
if ((result.suppressions & (1 << ANIMATION_TRIGGER_ALIAS_GEOMETRY)) != 0) {
const uint64_t to_set =
(1 << ANIMATION_TRIGGER_SIZE) | (1 << ANIMATION_TRIGGER_POSITION);
if ((result.suppressions & to_set) != 0) {
log_warn("Trigger \"geometry\" is an alias of \"size\" and "
"\"position\", but one or both of them are also set at "
"line %d",
config_setting_source_line(suppressions_setting));
}
result.suppressions |= to_set;
}
result.suppressions &= (1 << ANIMATION_TRIGGER_COUNT) - 1;
char *err;
if (!compile_win_script(&result, setting, &err)) {
log_error("Failed to parse animation script at line %d: %s",