From d6aef7b832cb3c74f0978cb67877211e501630d3 Mon Sep 17 00:00:00 2001 From: "Carsten \"Tomcat\" Book" Date: Fri, 16 Dec 2016 12:32:15 +0100 Subject: [PATCH] Backed out changeset 4bd98277bf9e (bug 1243415) --- testing/marionette/driver.js | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/testing/marionette/driver.js b/testing/marionette/driver.js index 6494ecff12a4..a628ca60f44a 100644 --- a/testing/marionette/driver.js +++ b/testing/marionette/driver.js @@ -2408,14 +2408,9 @@ GeckoDriver.prototype.takeScreenshot = function (cmd, resp) { switch (this.context) { case Context.CHROME: let canvas; + let container = {frame: this.getCurrentWindow()}; let highlightEls = []; - let container = {frame: this.getCurrentWindow().document.defaultView}; - - if (!container.frame) { - throw new NoSuchWindowError('Unable to locate window'); - } - for (let h of highlights) { let el = this.curBrowser.seenEls.get(h, container); highlightEls.push(el);