Commit 9209ec0b authored by Alice Boxhall's avatar Alice Boxhall Committed by Commit Bot

[Devtools] Focus wrapper div around iframe in extension views

Bug: 872438
Change-Id: I86931802744baa8d41a4c6ed2b1c89967fc47138
Reviewed-on: https://chromium-review.googlesource.com/c/1372105
Commit-Queue: Alice Boxhall <aboxhall@chromium.org>
Reviewed-by: default avatarJoel Einbinder <einbinder@chromium.org>
Cr-Commit-Position: refs/heads/master@{#615791}
parent f02c0f1a
...@@ -43,13 +43,18 @@ Extensions.ExtensionView = class extends UI.Widget { ...@@ -43,13 +43,18 @@ Extensions.ExtensionView = class extends UI.Widget {
this.setHideOnDetach(); this.setHideOnDetach();
this.element.className = 'vbox flex-auto'; // Override this.element.className = 'vbox flex-auto'; // Override
// TODO(crbug.com/872438): remove once we can use this._iframe instead
this.element.tabIndex = -1;
this._server = server; this._server = server;
this._id = id; this._id = id;
this._iframe = createElement('iframe'); this._iframe = createElement('iframe');
this._iframe.addEventListener('load', this._onLoad.bind(this), false); this._iframe.addEventListener('load', this._onLoad.bind(this), false);
this._iframe.src = src; this._iframe.src = src;
this._iframe.className = className; this._iframe.className = className;
this.setDefaultFocusedElement(this._iframe);
// TODO(crbug.com/872438): make this._iframe the default focused element
this.setDefaultFocusedElement(this.element);
this.element.appendChild(this._iframe); this.element.appendChild(this._iframe);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment