Open Bug 1766329 Opened 2 years ago Updated 9 months ago

browsingContext.create should not run the focus steps when opening a new window

Categories

(Remote Protocol :: WebDriver BiDi, task, P3)

task
Points:
8

Tracking

(Not tracked)

People

(Reporter: jdescottes, Unassigned)

References

(Blocks 1 open bug)

Details

(Whiteboard: [webdriver:backlog])

The current implementation of WindowManager.openBrowserWindow will always focus the new window, regardless of the value of the focus parameter. When focus is false, the method will simply re-focus the initial window after opening the current window.

Per WebDriver BiDi spec (as well as WebDriver classic), opening a new window should not run the focus steps:

This must be done without invoking the focusing steps for the created browsing context.

https://w3c.github.io/webdriver-bidi/#command-browsingContext-create

For the initial implementation of create, we are keeping the same behavior as in marionette, but we should change this to avoid focusing the new window.

Sidenote: when opening a new window with OpenBrowserWindow there doesn't seem to be a way to open a backgound window at the moment. However, even if the new window is in the foreground it is not in practice focused and doesn't trigger a blur on the original window.

Blocks: 1750547
Whiteboard: [webdriver:backlog]
Points: --- → 8
Priority: -- → P3
You need to log in before you can comment on or make changes to this bug.