| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2009 Joseph Pecoraro | 3 * Copyright (C) 2009 Joseph Pecoraro |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * | 8 * |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 581 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 592 if (request && request.resourceType() === WebInspector.resourceTypes.XHR
) { | 592 if (request && request.resourceType() === WebInspector.resourceTypes.XHR
) { |
| 593 contextMenu.appendSeparator(); | 593 contextMenu.appendSeparator(); |
| 594 contextMenu.appendItem(WebInspector.UIString("Replay XHR"), request.
replayXHR.bind(request)); | 594 contextMenu.appendItem(WebInspector.UIString("Replay XHR"), request.
replayXHR.bind(request)); |
| 595 } | 595 } |
| 596 | 596 |
| 597 contextMenu.show(); | 597 contextMenu.show(); |
| 598 }, | 598 }, |
| 599 | 599 |
| 600 _saveConsole: function() | 600 _saveConsole: function() |
| 601 { | 601 { |
| 602 var filename = String.sprintf("%s-%d.log", WebInspector.targetManager.in
spectedPageDomain(), Date.now()); | 602 var url = WebInspector.targetManager.mainTarget().inspectedURL(); |
| 603 var filename = String.sprintf("%s-%d.log", url.asParsedURL().host, Date.
now()); |
| 603 var stream = new WebInspector.FileOutputStream(); | 604 var stream = new WebInspector.FileOutputStream(); |
| 604 | 605 |
| 605 var progressIndicator = new WebInspector.ProgressIndicator(); | 606 var progressIndicator = new WebInspector.ProgressIndicator(); |
| 606 progressIndicator.setTitle(WebInspector.UIString("Writing file…")); | 607 progressIndicator.setTitle(WebInspector.UIString("Writing file…")); |
| 607 progressIndicator.setTotalWork(this.itemCount()); | 608 progressIndicator.setTotalWork(this.itemCount()); |
| 608 | 609 |
| 609 /** @const */ | 610 /** @const */ |
| 610 var chunkSize = 350; | 611 var chunkSize = 350; |
| 611 var messageIndex = 0; | 612 var messageIndex = 0; |
| 612 | 613 |
| (...skipping 725 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1338 return true; | 1339 return true; |
| 1339 } | 1340 } |
| 1340 return false; | 1341 return false; |
| 1341 } | 1342 } |
| 1342 } | 1343 } |
| 1343 | 1344 |
| 1344 /** | 1345 /** |
| 1345 * @typedef {{messageIndex: number, matchIndex: number}} | 1346 * @typedef {{messageIndex: number, matchIndex: number}} |
| 1346 */ | 1347 */ |
| 1347 WebInspector.ConsoleView.RegexMatchRange; | 1348 WebInspector.ConsoleView.RegexMatchRange; |
| OLD | NEW |