mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Improve inter-document focus handling (#36649)
*Describe the changes that this pull request makes here. This will be the commit message.* rewritten the PR #28571 Implement [Window#focus](https://html.spec.whatwg.org/multipage/#dom-window-focus), [Window#blur](https://html.spec.whatwg.org/multipage/#dom-window-blur) Testing: WPT Fixes: #8981 #9421 --------- Signed-off-by: kongbai1996 <1782765876@qq.com> Co-authored-by: yvt <i@yvt.jp>
This commit is contained in:
parent
27570987fd
commit
0c0ee04b8e
33 changed files with 1123 additions and 242 deletions
|
@ -181,12 +181,13 @@ impl DissimilarOriginWindowMethods<crate::DomTypeHolder> for DissimilarOriginWin
|
|||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-window-blur
|
||||
fn Blur(&self) {
|
||||
// TODO: Implement x-origin blur
|
||||
// > User agents are encouraged to ignore calls to this `blur()` method
|
||||
// > entirely.
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-focus
|
||||
// https://html.spec.whatwg.org/multipage/#dom-window-focus
|
||||
fn Focus(&self) {
|
||||
// TODO: Implement x-origin focus
|
||||
self.window_proxy().focus();
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-location
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue