| OLD | NEW |
| 1 function scheduleTestFunction() | 1 function scheduleTestFunction() |
| 2 { | 2 { |
| 3 setTimeout(testFunction, 0); | 3 setTimeout(testFunction, 0); |
| 4 } | 4 } |
| 5 | 5 |
| 6 var initialize_DebuggerTest = function() { | 6 var initialize_DebuggerTest = function() { |
| 7 | 7 |
| 8 InspectorTest.preloadPanel("sources"); | 8 InspectorTest.preloadPanel("sources"); |
| 9 | 9 |
| 10 InspectorTest.startDebuggerTest = function(callback, quiet) | 10 InspectorTest.startDebuggerTest = function(callback, quiet) |
| (...skipping 489 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 500 }; | 500 }; |
| 501 | 501 |
| 502 InspectorTest.createScriptMock = function(url, startLine, startColumn, isContent
Script, source, target, preRegisterCallback) | 502 InspectorTest.createScriptMock = function(url, startLine, startColumn, isContent
Script, source, target, preRegisterCallback) |
| 503 { | 503 { |
| 504 target = target || WebInspector.targetManager.mainTarget(); | 504 target = target || WebInspector.targetManager.mainTarget(); |
| 505 var debuggerModel = WebInspector.DebuggerModel.fromTarget(target); | 505 var debuggerModel = WebInspector.DebuggerModel.fromTarget(target); |
| 506 var scriptId = ++InspectorTest._lastScriptId + ""; | 506 var scriptId = ++InspectorTest._lastScriptId + ""; |
| 507 var lineCount = source.lineEndings().length; | 507 var lineCount = source.lineEndings().length; |
| 508 var endLine = startLine + lineCount - 1; | 508 var endLine = startLine + lineCount - 1; |
| 509 var endColumn = lineCount === 1 ? startColumn + source.length : source.lengt
h - source.lineEndings()[lineCount - 2]; | 509 var endColumn = lineCount === 1 ? startColumn + source.length : source.lengt
h - source.lineEndings()[lineCount - 2]; |
| 510 var hasSourceURL = !!source.match(/\/\/#\ssourceURL=\s*(\S*?)\s*$/m) || !!so
urce.match(/\/\/@\ssourceURL=\s*(\S*?)\s*$/m); | 510 var hasSourceURL = !!source.match(/\/\/#\ssourceURL=\s*(\S*?)\s*$/m); |
| 511 var script = new WebInspector.Script(debuggerModel, scriptId, url, startLine
, startColumn, endLine, endColumn, isContentScript, null, hasSourceURL); | 511 var script = new WebInspector.Script(debuggerModel, scriptId, url, startLine
, startColumn, endLine, endColumn, isContentScript, null, hasSourceURL); |
| 512 script.requestContent = function(callback) | 512 script.requestContent = function(callback) |
| 513 { | 513 { |
| 514 var trimmedSource = WebInspector.Script._trimSourceURLComment(source); | 514 var trimmedSource = WebInspector.Script._trimSourceURLComment(source); |
| 515 callback(trimmedSource, false, "text/javascript"); | 515 callback(trimmedSource, false, "text/javascript"); |
| 516 }; | 516 }; |
| 517 if (preRegisterCallback) | 517 if (preRegisterCallback) |
| 518 preRegisterCallback(script); | 518 preRegisterCallback(script); |
| 519 debuggerModel._registerScript(script); | 519 debuggerModel._registerScript(script); |
| 520 return script; | 520 return script; |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 564 } | 564 } |
| 565 | 565 |
| 566 InspectorTest.selectThread = function(target) | 566 InspectorTest.selectThread = function(target) |
| 567 { | 567 { |
| 568 var threadsPane = WebInspector.panels.sources.sidebarPanes.threads; | 568 var threadsPane = WebInspector.panels.sources.sidebarPanes.threads; |
| 569 var listItem = threadsPane._debuggerModelToListItems.get(WebInspector.Debugg
erModel.fromTarget(target)); | 569 var listItem = threadsPane._debuggerModelToListItems.get(WebInspector.Debugg
erModel.fromTarget(target)); |
| 570 threadsPane._onListItemClick(listItem); | 570 threadsPane._onListItemClick(listItem); |
| 571 } | 571 } |
| 572 | 572 |
| 573 }; | 573 }; |
| OLD | NEW |