mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
Update select shadow tree when contents of selected option change (#36958)
The label that is displayed inside a `<select>` element is that of the selected option, or it's text contents if the option does not have a label. Therefore, we need to update the `<select>` shadow tree when the contents of the selected option change. Testing: Covered by existing web platform tests Fixes https://github.com/servo/servo/issues/36926 Fixes https://github.com/servo/servo/issues/36925 --------- Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
This commit is contained in:
parent
fec6778eaa
commit
41283220dd
5 changed files with 32 additions and 11 deletions
|
@ -135,8 +135,8 @@ impl VirtualMethods for HTMLOptGroupElement {
|
|||
}
|
||||
|
||||
fn bind_to_tree(&self, context: &BindContext, can_gc: CanGc) {
|
||||
if let Some(s) = self.super_type() {
|
||||
s.bind_to_tree(context, can_gc);
|
||||
if let Some(super_type) = self.super_type() {
|
||||
super_type.bind_to_tree(context, can_gc);
|
||||
}
|
||||
|
||||
self.update_select_validity(can_gc);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue