Skip to content

htmlmediaelement: Make dirty element on any intrinsic size changes#37056

Merged
jdm merged 1 commit intoservo:mainfrom
tharkum:hmtlmediaelement-node-damage-on-metadata-update
May 21, 2025
Merged

htmlmediaelement: Make dirty element on any intrinsic size changes#37056
jdm merged 1 commit intoservo:mainfrom
tharkum:hmtlmediaelement-node-damage-on-metadata-update

Conversation

@tharkum
Copy link
Contributor

@tharkum tharkum commented May 20, 2025

To properly compute (the video) element's content size for
layout requires to dirty the element on any intrinstic size changes.

Full list of the operations which cause layout invalidation:

  • media metadata update (NEW)
  • removing "src" attribute
  • video frame update
  • show poster image

Testing: html/semantics/embedded-content/the-video-element/intrinsic_sizes.htm
Fixes: #34434

@tharkum tharkum requested a review from gterzian as a code owner May 20, 2025 13:59
@tharkum
Copy link
Contributor Author

tharkum commented May 20, 2025

@tharkum
Copy link
Contributor Author

tharkum commented May 20, 2025

cc @xiaochengh

@tharkum tharkum force-pushed the hmtlmediaelement-node-damage-on-metadata-update branch from c6f9705 to 06c020c Compare May 21, 2025 06:18
@tharkum tharkum changed the title htmlmediaelement: Dirty element on media metadata processing htmlmediaelement: Make dirty element on an intrinsic size changes May 21, 2025
@tharkum tharkum changed the title htmlmediaelement: Make dirty element on an intrinsic size changes htmlmediaelement: Make dirty element on any intrinsic size changes May 21, 2025
@tharkum
Copy link
Contributor Author

tharkum commented May 21, 2025

Linux WPT results (PASSED): https://github.com/tharkum/servo/actions/runs/15154968507

To properly compute (the video) element's content size for
layout requires to dirty the element on any intrinstic size changes.

Full list of the operations which cause layout invalidation:
- media metadata update (NEW)
- removing "src" attribute
- video frame update
- show poster image

Fixes: servo#34434

Signed-off-by: Andrei Volykhin <andrei.volykhin@gmail.com>
@tharkum tharkum force-pushed the hmtlmediaelement-node-damage-on-metadata-update branch from 06c020c to acb3b5a Compare May 21, 2025 10:47
@jdm jdm enabled auto-merge May 21, 2025 10:48
@tharkum
Copy link
Contributor Author

tharkum commented May 21, 2025

  • Rebased om main branch
  • Added missing WPT result (after rebase)

@jdm jdm added this pull request to the merge queue May 21, 2025
Merged via the queue into servo:main with commit 859a0ff May 21, 2025
21 checks passed
@tharkum tharkum deleted the hmtlmediaelement-node-damage-on-metadata-update branch May 21, 2025 12:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Intermittent failure in /html/semantics/embedded-content/the-video-element/intrinsic_sizes.htm

2 participants