Bug 1288147 - don't use ownerGlobal in devtools client code; r=bgrins

MozReview-Commit-ID: EgXSMILZrri

--HG--
extra : rebase_source : 8a1ec7e1458fe2b2844ba8d2e70803da4eb05199
This commit is contained in:
Tom Tromey 2016-07-26 09:34:25 -06:00
Родитель ea95071431
Коммит bbb5d58ec6
4 изменённых файлов: 4 добавлений и 4 удалений

Просмотреть файл

@ -2092,7 +2092,7 @@ Toolbox.prototype = {
this._threadClient = null;
// We need to grab a reference to win before this._host is destroyed.
let win = this.frame.ownerGlobal;
let win = this.frame.ownerDocument.defaultView;
if (this._requisition) {
CommandUtils.destroyRequisition(this._requisition, this.target);

Просмотреть файл

@ -119,7 +119,7 @@ const SPECIAL_VALUES = new Set(["none", "unset", "initial", "inherit"]);
*/
function CSSFilterEditorWidget(el, value = "") {
this.doc = el.ownerDocument;
this.win = this.doc.ownerGlobal;
this.win = this.doc.defaultView;
this.el = el;
this._addButtonClick = this._addButtonClick.bind(this);

Просмотреть файл

@ -1778,7 +1778,7 @@ EditableFieldsEngine.prototype = {
* The node to copy styles to.
*/
copyStyles: function (source, destination) {
let style = source.ownerGlobal.getComputedStyle(source);
let style = source.ownerDocument.defaultView.getComputedStyle(source);
let props = [
"borderTopWidth",
"borderRightWidth",

Просмотреть файл

@ -957,7 +957,7 @@ StyleEditorUI.prototype = {
*/
_launchResponsiveMode: Task.async(function* (options = {}) {
let tab = this._target.tab;
let win = this._target.tab.ownerGlobal;
let win = this._target.tab.ownerDocument.defaultView;
yield ResponsiveUIManager.runIfNeeded(win, tab);
if (options.width && options.height) {