From 5bfbba28c696dd6fcf2abd262ed0ef2571a77fcd Mon Sep 17 00:00:00 2001 From: Jan Odvarko Date: Thu, 6 Jul 2017 14:27:10 +0200 Subject: [PATCH] Bug 1378738 - Stop using sdk/window/utils in Netmonitor; r=rickychien MozReview-Commit-ID: 4Z4pDHxhbZN --HG-- extra : rebase_source : febe5d1737f7d80711aa890065308dd9422236d7 --- devtools/client/netmonitor/src/har/har-utils.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/devtools/client/netmonitor/src/har/har-utils.js b/devtools/client/netmonitor/src/har/har-utils.js index bb984d33ca47..ce0a789b8f62 100644 --- a/devtools/client/netmonitor/src/har/har-utils.js +++ b/devtools/client/netmonitor/src/har/har-utils.js @@ -6,8 +6,10 @@ "use strict"; +const Services = require("Services"); const { Ci, Cc, CC } = require("chrome"); const { XPCOMUtils } = require("resource://gre/modules/XPCOMUtils.jsm"); +const { gDevTools } = require("devtools/client/framework/devtools"); XPCOMUtils.defineLazyGetter(this, "dirService", function () { return Cc["@mozilla.org/file/directory_service;1"] @@ -23,7 +25,7 @@ XPCOMUtils.defineLazyGetter(this, "LocalFile", function () { }); XPCOMUtils.defineLazyGetter(this, "getMostRecentBrowserWindow", function () { - return require("sdk/window/utils").getMostRecentBrowserWindow; + return Services.wm.getMostRecentWindow(gDevTools.chromeWindowType); }); const OPEN_FLAGS = {