Open Bug 1891755 Opened 2 years ago Updated 2 years ago

Browser Toolbox inspector should switch iframes when focusing on elements in different browser windows

Categories

(DevTools :: Inspector, defect, P3)

defect

Tracking

(Not tracked)

People

(Reporter: gregtatum, Unassigned)

References

(Depends on 1 open bug, Blocks 1 open bug)

Details

Attachments

(1 file)

Steps to reproduce:

  • Open two browser windows (window 1, and window 2).
  • Open the multiprocess browser toolbox.
  • Change focus on window 1
  • Change focus on the toolbox
  • Use the "pick an element" button to select something on the window 1
  • Observe that the inspector pulls up the element in the view.
  • Change focus to window 2
  • Change focus to the toolbox
  • Use the "pick an element" button to select something on window 2

Expected results:

  • The inspector should switch the "iframe" to the second chrome://browser/content/browser.xhtml
  • The inspector tree view should show the contents of window 2

Actual results:

  • The inspector continues to show the chrome://browser/content/browser.xhtml for window 1.

The node picker actor only cares about a single window/docshell at the moment, but we could add listeners to all the toplevel docshells and force a top level document change on demand. I have a quick patch that seems to work but it might be the wrong approach. Will upload it in case it can help.

The current patch is relying on the iframe dropdown, which will no longer be relevant once we migrate to EFT for the Browser Toolbox. So we should probably not move forward with this and rather resume this once EFT is used as well for the browser toolbox.

See Bug 1785266 and related bugs for the remaining EFT work.

Severity: -- → S3
Depends on: 1785266
Priority: -- → P3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: