Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4558)

Unified Diff: chrome/renderer/resources/extensions/binding.js

Issue 13726026: Added ActivityLog tests and associated bugfixes/extra logging. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Wrapped line Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/renderer/resources/extensions/binding.js
diff --git a/chrome/renderer/resources/extensions/binding.js b/chrome/renderer/resources/extensions/binding.js
index 80c81242e7d2ca63da64bb1a40bcb68829ee973e..c7b299a825742573594eb137f2b6892c50a0f07f 100644
--- a/chrome/renderer/resources/extensions/binding.js
+++ b/chrome/renderer/resources/extensions/binding.js
@@ -19,7 +19,7 @@ var utils = require('utils');
var CHECK = requireNative('logging').CHECK;
var sendRequestHandler = require('sendRequest');
var sendRequest = sendRequestHandler.sendRequest;
-var logActivity = requireNative('activityLogger').LogActivity;
+var logActivity = requireNative('activityLogger');
// Stores the name and definition of each API function, with methods to
// modify their behaviour (such as a custom way to handle requests to the
@@ -53,13 +53,14 @@ APIFunctions.prototype.setHook_ =
APIFunctions.prototype.setHandleRequest =
function(apiName, customizedFunction) {
var prefix = this.namespace;
+ // TODO(ataly): Need to replace/redefine apply and slice.
return this.setHook_(apiName, 'handleRequest',
function() {
var ret = customizedFunction.apply(this, arguments);
// Logs API calls to the Activity Log if it doesn't go through an
// ExtensionFunction.
if (!sendRequestHandler.getCalledSendRequest())
- logActivity(extensionId, prefix + "." + apiName,
+ logActivity.LogAPICall(extensionId, prefix + "." + apiName,
Array.prototype.slice.call(arguments));
return ret;
});

Powered by Google App Engine
This is Rietveld 408576698