Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: lib/child/contentPolicy.js

Issue 29329810: Issue 3274 - Unbreak collecting window stats (Closed)
Patch Set: Created Nov. 6, 2015, 12:35 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | lib/child/requestNotifier.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/child/contentPolicy.js
===================================================================
--- a/lib/child/contentPolicy.js
+++ b/lib/child/contentPolicy.js
@@ -68,27 +68,27 @@ let types = new Map();
let shouldAllow = exports.shouldAllow = function(window, node, contentType, location, callback)
{
function processResponse(response)
{
if (typeof response == "undefined")
return true;
let {allow, collapse, hits} = response;
- for (let {frameIndex, contentType, docDomain, thirdParty, location, filter} of hits)
+ for (let hit of hits)
{
let context = node;
- if (typeof frameIndex == "number")
+ if (typeof hit.frameIndex == "number")
{
context = window;
- for (let i = 0; i < frameIndex; i++)
+ for (let i = 0; i < hit.frameIndex; i++)
context = context.parent;
context = context.document;
}
- RequestNotifier.addNodeData(context, window.top, contentType, docDomain, thirdParty, location, filter);
+ RequestNotifier.addNodeData(context, window.top, hit);
}
if (node.nodeType == Ci.nsIDOMNode.ELEMENT_NODE)
{
// Track mouse events for objects
if (allow && contentType == "OBJECT")
{
node.addEventListener("mouseover", objectMouseEventHander, true);
« no previous file with comments | « no previous file | lib/child/requestNotifier.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld