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

Side by Side Diff: Source/core/inspector/InjectedScriptSource.js

Issue 16143005: monitor console command implemented. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2007 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 1141 matching lines...) Expand 10 before | Expand all | Expand 10 after
1152 } 1152 }
1153 1153
1154 // NOTE: Please keep the list of API methods below snchronized to that in WebIns pector.RuntimeModel! 1154 // NOTE: Please keep the list of API methods below snchronized to that in WebIns pector.RuntimeModel!
1155 /** 1155 /**
1156 * @type {Array.<string>} 1156 * @type {Array.<string>}
1157 * @const 1157 * @const
1158 */ 1158 */
1159 CommandLineAPI.members_ = [ 1159 CommandLineAPI.members_ = [
1160 "$", "$$", "$x", "dir", "dirxml", "keys", "values", "profile", "profileEnd", 1160 "$", "$$", "$x", "dir", "dirxml", "keys", "values", "profile", "profileEnd",
1161 "monitorEvents", "unmonitorEvents", "inspect", "copy", "clear", "getEventLis teners", 1161 "monitorEvents", "unmonitorEvents", "inspect", "copy", "clear", "getEventLis teners",
1162 "debug", "undebug", "table" 1162 "debug", "undebug", "monitor", "unmonitor", "table"
1163 ]; 1163 ];
1164 1164
1165 /** 1165 /**
1166 * @constructor 1166 * @constructor
1167 */ 1167 */
1168 function CommandLineAPIImpl() 1168 function CommandLineAPIImpl()
1169 { 1169 {
1170 } 1170 }
1171 1171
1172 CommandLineAPIImpl.prototype = { 1172 CommandLineAPIImpl.prototype = {
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
1311 /** 1311 /**
1312 * @param {Node} node 1312 * @param {Node} node
1313 */ 1313 */
1314 getEventListeners: function(node) 1314 getEventListeners: function(node)
1315 { 1315 {
1316 return InjectedScriptHost.getEventListeners(node); 1316 return InjectedScriptHost.getEventListeners(node);
1317 }, 1317 },
1318 1318
1319 debug: function(fn) 1319 debug: function(fn)
1320 { 1320 {
1321 InjectedScriptHost.setBreakpoint(fn); 1321 InjectedScriptHost.debugFunction(fn);
1322 }, 1322 },
1323 1323
1324 undebug: function(fn) 1324 undebug: function(fn)
1325 { 1325 {
1326 InjectedScriptHost.removeBreakpoint(fn); 1326 InjectedScriptHost.undebugFunction(fn);
1327 },
1328
1329 monitor: function(fn)
1330 {
1331 InjectedScriptHost.monitorFunction(fn);
1332 },
1333
1334 unmonitor: function(fn) {
1335 InjectedScriptHost.unmonitorFunction(fn);
1327 }, 1336 },
1328 1337
1329 table: function() 1338 table: function()
1330 { 1339 {
1331 inspectedWindow.console.table.apply(inspectedWindow.console, arguments); 1340 inspectedWindow.console.table.apply(inspectedWindow.console, arguments);
1332 }, 1341 },
1333 1342
1334 /** 1343 /**
1335 * @param {number} num 1344 * @param {number} num
1336 */ 1345 */
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
1371 */ 1380 */
1372 _logEvent: function(event) 1381 _logEvent: function(event)
1373 { 1382 {
1374 inspectedWindow.console.log(event.type, event); 1383 inspectedWindow.console.log(event.type, event);
1375 } 1384 }
1376 } 1385 }
1377 1386
1378 injectedScript._commandLineAPIImpl = new CommandLineAPIImpl(); 1387 injectedScript._commandLineAPIImpl = new CommandLineAPIImpl();
1379 return injectedScript; 1388 return injectedScript;
1380 }) 1389 })
OLDNEW
« no previous file with comments | « Source/core/inspector/InjectedScriptHost.idl ('k') | Source/core/inspector/InspectorDebuggerAgent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698