LibWeb: Don't consider null -> null as a change for invalidation
Some checks are pending
CI / macOS, arm64, Sanitizer, Clang (push) Waiting to run
CI / Linux, x86_64, Fuzzers, Clang (push) Waiting to run
CI / Linux, x86_64, Sanitizer, GNU (push) Waiting to run
CI / Linux, x86_64, Sanitizer, Clang (push) Waiting to run
Package the js repl as a binary artifact / Linux, arm64 (push) Waiting to run
Package the js repl as a binary artifact / macOS, arm64 (push) Waiting to run
Package the js repl as a binary artifact / Linux, x86_64 (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Label PRs with merge conflicts / auto-labeler (push) Waiting to run
Push notes / build (push) Waiting to run

This avoids excessive invalidation within `recompute_inherited_style`
where we inherit a value but not an animated value.
This commit is contained in:
Callum Law 2025-08-22 16:43:56 +12:00 committed by Jelle Raaijmakers
commit 5c2fe12772
Notes: github-actions[bot] 2025-08-22 10:19:01 +00:00

View file

@ -15,7 +15,7 @@ RequiredInvalidationAfterStyleChange compute_property_invalidation(CSS::Property
{ {
RequiredInvalidationAfterStyleChange invalidation; RequiredInvalidationAfterStyleChange invalidation;
bool const property_value_changed = (!old_value || !new_value) || *old_value != *new_value; bool const property_value_changed = (old_value || new_value) && ((!old_value || !new_value) || *old_value != *new_value);
if (!property_value_changed) if (!property_value_changed)
return invalidation; return invalidation;