| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2013 The Native Client Authors. All rights reserved. | 2 * Copyright (c) 2013 The Native Client Authors. All rights reserved. |
| 3 * Use of this source code is governed by a BSD-style license that can be | 3 * Use of this source code is governed by a BSD-style license that can be |
| 4 * found in the LICENSE file. | 4 * found in the LICENSE file. |
| 5 */ | 5 */ |
| 6 | 6 |
| 7 'use strict'; | 7 'use strict'; |
| 8 | 8 |
| 9 // The background page of the gdb chrome packaged app exists solely to | 9 // The background page of the gdb chrome packaged app exists solely to |
| 10 // manage the set of operations that can only be performed in a v2 chrome app, | 10 // manage the set of operations that can only be performed in a v2 chrome app, |
| (...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 354 | 354 |
| 355 var argv = [ | 355 var argv = [ |
| 356 '-ex', 'target remote :' + self.debugTcpPort_, | 356 '-ex', 'target remote :' + self.debugTcpPort_, |
| 357 ]; | 357 ]; |
| 358 argv = ['gdb.nmf'].concat(argv); | 358 argv = ['gdb.nmf'].concat(argv); |
| 359 | 359 |
| 360 var argn = 0; | 360 var argn = 0; |
| 361 argv.forEach(function(arg) { | 361 argv.forEach(function(arg) { |
| 362 var argname = 'arg' + argn; | 362 var argname = 'arg' + argn; |
| 363 addParam(argname, arg); | 363 addParam(argname, arg); |
| 364 argn = argn + 1 | 364 argn = argn + 1; |
| 365 }); | 365 }); |
| 366 | 366 |
| 367 document.body.appendChild(gdb); | 367 document.body.appendChild(gdb); |
| 368 // Work around crbug.com/350445 | 368 // Work around crbug.com/350445 |
| 369 var junk = gdb.offsetTop; | 369 var junk = gdb.offsetTop; |
| 370 }; | 370 }; |
| 371 | 371 |
| 372 /** | 372 /** |
| 373 * Suspend with javascript, then attach a GDB instance. | 373 * Suspend with javascript, then attach a GDB instance. |
| 374 */ | 374 */ |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 436 if (navigator.userAgent.indexOf('ChromeTestAgent/') < 0) { | 436 if (navigator.userAgent.indexOf('ChromeTestAgent/') < 0) { |
| 437 // TODO(bradnelson): Enable this check once a production extension id is | 437 // TODO(bradnelson): Enable this check once a production extension id is |
| 438 // known for the debugger extension. | 438 // known for the debugger extension. |
| 439 //if (port.sender.id !== 'blessed-id') { | 439 //if (port.sender.id !== 'blessed-id') { |
| 440 // port.disconnect(); | 440 // port.disconnect(); |
| 441 // return; | 441 // return; |
| 442 //} | 442 //} |
| 443 } | 443 } |
| 444 var dc = new DebugConnection_(port); | 444 var dc = new DebugConnection_(port); |
| 445 }); | 445 }); |
| OLD | NEW |