| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2012 Intel Inc. All rights reserved. | 3 * Copyright (C) 2012 Intel Inc. All rights reserved. |
| 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 are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * 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 410 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 421 detailsText = WebInspector.UIString("%d\u2009\u00d7\u2009%d", width,
height); | 421 detailsText = WebInspector.UIString("%d\u2009\u00d7\u2009%d", width,
height); |
| 422 break; | 422 break; |
| 423 case recordType.ParseHTML: | 423 case recordType.ParseHTML: |
| 424 var endLine = event.args["endData"] && event.args["endData"]["endLine"]; | 424 var endLine = event.args["endData"] && event.args["endData"]["endLine"]; |
| 425 var url = WebInspector.displayNameForURL(event.args["beginData"]["url"])
; | 425 var url = WebInspector.displayNameForURL(event.args["beginData"]["url"])
; |
| 426 detailsText = WebInspector.UIString("%s [%s\u2026%s]", url, event.args["
beginData"]["startLine"] + 1, endLine >= 0 ? endLine + 1 : ""); | 426 detailsText = WebInspector.UIString("%s [%s\u2026%s]", url, event.args["
beginData"]["startLine"] + 1, endLine >= 0 ? endLine + 1 : ""); |
| 427 break; | 427 break; |
| 428 | 428 |
| 429 case recordType.CompileScript: | 429 case recordType.CompileScript: |
| 430 case recordType.EvaluateScript: | 430 case recordType.EvaluateScript: |
| 431 var url = eventData["url"]; | 431 var url = eventData && eventData["url"]; |
| 432 if (url) | 432 if (url) |
| 433 detailsText = WebInspector.displayNameForURL(url) + ":" + (eventData
["lineNumber"] + 1); | 433 detailsText = WebInspector.displayNameForURL(url) + ":" + (eventData
["lineNumber"] + 1); |
| 434 break; | 434 break; |
| 435 case recordType.ParseScriptOnBackground: | 435 case recordType.ParseScriptOnBackground: |
| 436 case recordType.XHRReadyStateChange: | 436 case recordType.XHRReadyStateChange: |
| 437 case recordType.XHRLoad: | 437 case recordType.XHRLoad: |
| 438 var url = eventData["url"]; | 438 var url = eventData["url"]; |
| 439 if (url) | 439 if (url) |
| 440 detailsText = WebInspector.displayNameForURL(url); | 440 detailsText = WebInspector.displayNameForURL(url); |
| 441 break; | 441 break; |
| (...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 751 contentHelper.appendTextRow(WebInspector.UIString("MIME Type"), even
tData["mimeType"]); | 751 contentHelper.appendTextRow(WebInspector.UIString("MIME Type"), even
tData["mimeType"]); |
| 752 if ("priority" in eventData) { | 752 if ("priority" in eventData) { |
| 753 var priority = WebInspector.uiLabelForPriority(eventData["priority"]
); | 753 var priority = WebInspector.uiLabelForPriority(eventData["priority"]
); |
| 754 contentHelper.appendTextRow(WebInspector.UIString("Priority"), prior
ity); | 754 contentHelper.appendTextRow(WebInspector.UIString("Priority"), prior
ity); |
| 755 } | 755 } |
| 756 if (eventData["encodedDataLength"]) | 756 if (eventData["encodedDataLength"]) |
| 757 contentHelper.appendTextRow(WebInspector.UIString("Encoded Data Leng
th"), WebInspector.UIString("%d Bytes", eventData["encodedDataLength"])); | 757 contentHelper.appendTextRow(WebInspector.UIString("Encoded Data Leng
th"), WebInspector.UIString("%d Bytes", eventData["encodedDataLength"])); |
| 758 break; | 758 break; |
| 759 case recordTypes.CompileScript: | 759 case recordTypes.CompileScript: |
| 760 case recordTypes.EvaluateScript: | 760 case recordTypes.EvaluateScript: |
| 761 var url = eventData["url"]; | 761 var url = eventData && eventData["url"]; |
| 762 if (url) | 762 if (url) |
| 763 contentHelper.appendLocationRow(WebInspector.UIString("Script"), url
, eventData["lineNumber"], eventData["columnNumber"]); | 763 contentHelper.appendLocationRow(WebInspector.UIString("Script"), url
, eventData["lineNumber"], eventData["columnNumber"]); |
| 764 break; | 764 break; |
| 765 case recordTypes.Paint: | 765 case recordTypes.Paint: |
| 766 var clip = eventData["clip"]; | 766 var clip = eventData["clip"]; |
| 767 contentHelper.appendTextRow(WebInspector.UIString("Location"), WebInspec
tor.UIString("(%d, %d)", clip[0], clip[1])); | 767 contentHelper.appendTextRow(WebInspector.UIString("Location"), WebInspec
tor.UIString("(%d, %d)", clip[0], clip[1])); |
| 768 var clipWidth = WebInspector.TimelineUIUtils.quadWidth(clip); | 768 var clipWidth = WebInspector.TimelineUIUtils.quadWidth(clip); |
| 769 var clipHeight = WebInspector.TimelineUIUtils.quadHeight(clip); | 769 var clipHeight = WebInspector.TimelineUIUtils.quadHeight(clip); |
| 770 contentHelper.appendTextRow(WebInspector.UIString("Dimensions"), WebInsp
ector.UIString("%d × %d", clipWidth, clipHeight)); | 770 contentHelper.appendTextRow(WebInspector.UIString("Dimensions"), WebInsp
ector.UIString("%d × %d", clipWidth, clipHeight)); |
| 771 // Fall-through intended. | 771 // Fall-through intended. |
| (...skipping 1373 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2145 case warnings.V8Deopt: | 2145 case warnings.V8Deopt: |
| 2146 span.appendChild(WebInspector.linkifyURLAsNode("https://github.com/Googl
eChrome/devtools-docs/issues/53", | 2146 span.appendChild(WebInspector.linkifyURLAsNode("https://github.com/Googl
eChrome/devtools-docs/issues/53", |
| 2147 WebInspector.UIString("Not optimized"), undefined, true)); | 2147 WebInspector.UIString("Not optimized"), undefined, true)); |
| 2148 span.createTextChild(WebInspector.UIString(": %s", eventData["deoptReaso
n"])); | 2148 span.createTextChild(WebInspector.UIString(": %s", eventData["deoptReaso
n"])); |
| 2149 break; | 2149 break; |
| 2150 default: | 2150 default: |
| 2151 console.assert(false, "Unhandled TimelineModel.WarningType"); | 2151 console.assert(false, "Unhandled TimelineModel.WarningType"); |
| 2152 } | 2152 } |
| 2153 return span; | 2153 return span; |
| 2154 } | 2154 } |
| OLD | NEW |