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

Unified Diff: assets/js/XMLHttpRequest.jsm

Issue 8771172: adblockplusandroid: Initialise members on the instance, not the prototype (Closed)
Patch Set: Created Nov. 14, 2012, 11:10 a.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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: assets/js/XMLHttpRequest.jsm
===================================================================
--- a/assets/js/XMLHttpRequest.jsm
+++ b/assets/js/XMLHttpRequest.jsm
@@ -3,6 +3,16 @@
{
this.headers = {};
this.responseHeaders = {};
+ this.progressEventListeners = [];
+ this.loadendEventListeners = [];
+ this.loadEventListeners = [];
+ this.errorEventListeners = [];
+ this.abortEventListeners = [];
+ this.aborted = false;
+ this.async = true;
+ this.readyState = XMLHttpRequest.UNSENT;
+ this.responseText = "";
+ this.status = 0;
};
XMLHttpRequest.UNSENT = 0;
@@ -143,17 +153,7 @@
var listener = listeners[i];
listener();
}
- },
- progressEventListeners: [],
- loadendEventListeners: [],
- loadEventListeners: [],
- errorEventListeners: [],
- abortEventListeners: [],
- aborted: false,
- async: true,
- readyState: XMLHttpRequest.UNSENT,
- responseText: "",
- status: 0
+ }
};
XMLHttpRequest.prototype.channel =
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld