Make clicking on an element request focus for focusable elements.

This commit is contained in:
Josh Matthews 2020-06-12 17:35:58 -04:00
parent a34d1573b6
commit 757371f4f0
5 changed files with 46 additions and 24 deletions

View file

@ -2504,9 +2504,7 @@ impl ScriptThread {
let frame_element = doc.find_iframe(browsing_context_id);
if let Some(ref frame_element) = frame_element {
doc.begin_focus_transaction();
doc.request_focus(frame_element.upcast());
doc.commit_focus_transaction(FocusType::Parent);
doc.request_focus(Some(frame_element.upcast()), FocusType::Parent);
}
}