OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 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 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 columns.push({id: "function", title: WebInspector.UIString("Function"), disc
losure: true, sortable: true}); | 45 columns.push({id: "function", title: WebInspector.UIString("Function"), disc
losure: true, sortable: true}); |
46 | 46 |
47 this.dataGrid = new WebInspector.DataGrid(columns); | 47 this.dataGrid = new WebInspector.DataGrid(columns); |
48 this.dataGrid.addEventListener(WebInspector.DataGrid.Events.SortingChanged,
this._sortProfile, this); | 48 this.dataGrid.addEventListener(WebInspector.DataGrid.Events.SortingChanged,
this._sortProfile, this); |
49 this.dataGrid.element.addEventListener("mousedown", this._mouseDownInDataGri
d.bind(this), true); | 49 this.dataGrid.element.addEventListener("mousedown", this._mouseDownInDataGri
d.bind(this), true); |
50 this.dataGrid.show(this.element); | 50 this.dataGrid.show(this.element); |
51 | 51 |
52 this.viewSelectComboBox = new WebInspector.StatusBarComboBox(this._changeVie
w.bind(this)); | 52 this.viewSelectComboBox = new WebInspector.StatusBarComboBox(this._changeVie
w.bind(this)); |
53 | 53 |
54 var options = {}; | 54 var options = {}; |
55 options[WebInspector.CPUProfileView._TypeFlame] = this.viewSelectComboBox.cr
eateOption(WebInspector.UIString("Icicle Chart"), "", WebInspector.CPUProfileVie
w._TypeFlame); | 55 options[WebInspector.CPUProfileView._TypeFlame] = this.viewSelectComboBox.cr
eateOption(WebInspector.UIString("Chart"), "", WebInspector.CPUProfileView._Type
Flame); |
56 options[WebInspector.CPUProfileView._TypeHeavy] = this.viewSelectComboBox.cr
eateOption(WebInspector.UIString("Heavy (Bottom Up)"), "", WebInspector.CPUProfi
leView._TypeHeavy); | 56 options[WebInspector.CPUProfileView._TypeHeavy] = this.viewSelectComboBox.cr
eateOption(WebInspector.UIString("Heavy (Bottom Up)"), "", WebInspector.CPUProfi
leView._TypeHeavy); |
57 options[WebInspector.CPUProfileView._TypeTree] = this.viewSelectComboBox.cre
ateOption(WebInspector.UIString("Tree (Top Down)"), "", WebInspector.CPUProfileV
iew._TypeTree); | 57 options[WebInspector.CPUProfileView._TypeTree] = this.viewSelectComboBox.cre
ateOption(WebInspector.UIString("Tree (Top Down)"), "", WebInspector.CPUProfileV
iew._TypeTree); |
58 | 58 |
59 var optionName = this._viewType.get() || WebInspector.CPUProfileView._TypeFl
ame; | 59 var optionName = this._viewType.get() || WebInspector.CPUProfileView._TypeFl
ame; |
60 var option = options[optionName] || options[WebInspector.CPUProfileView._Typ
eFlame]; | 60 var option = options[optionName] || options[WebInspector.CPUProfileView._Typ
eFlame]; |
61 this.viewSelectComboBox.select(option); | 61 this.viewSelectComboBox.select(option); |
62 | 62 |
63 this._statusBarButtonsElement = document.createElement("span"); | 63 this._statusBarButtonsElement = document.createElement("span"); |
64 | 64 |
65 this.percentButton = new WebInspector.StatusBarButton("", "percent-time-stat
us-bar-item"); | 65 this.percentButton = new WebInspector.StatusBarButton("", "percent-time-stat
us-bar-item"); |
(...skipping 1319 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1385 | 1385 |
1386 /** | 1386 /** |
1387 * @param {number} entryIndex | 1387 * @param {number} entryIndex |
1388 * @return {!string} | 1388 * @return {!string} |
1389 */ | 1389 */ |
1390 textColor: function(entryIndex) | 1390 textColor: function(entryIndex) |
1391 { | 1391 { |
1392 return "#333"; | 1392 return "#333"; |
1393 } | 1393 } |
1394 } | 1394 } |
OLD | NEW |