OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google 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 are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 753 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
764 { | 764 { |
765 var selectedNode = event.target.selectedNode; | 765 var selectedNode = event.target.selectedNode; |
766 this._setRetainmentDataGridSource(selectedNode); | 766 this._setRetainmentDataGridSource(selectedNode); |
767 this._inspectedObjectChanged(event); | 767 this._inspectedObjectChanged(event); |
768 }, | 768 }, |
769 | 769 |
770 _onSelectAllocationNode: function(event) | 770 _onSelectAllocationNode: function(event) |
771 { | 771 { |
772 var selectedNode = event.target.selectedNode; | 772 var selectedNode = event.target.selectedNode; |
773 this._constructorsDataGrid.setAllocationNodeId(selectedNode.allocationNo
deId()); | 773 this._constructorsDataGrid.setAllocationNodeId(selectedNode.allocationNo
deId()); |
| 774 this._setRetainmentDataGridSource(null); |
774 }, | 775 }, |
775 | 776 |
776 _inspectedObjectChanged: function(event) | 777 _inspectedObjectChanged: function(event) |
777 { | 778 { |
778 var selectedNode = event.target.selectedNode; | 779 var selectedNode = event.target.selectedNode; |
779 if (!this._profile.fromFile() && selectedNode instanceof WebInspector.He
apSnapshotGenericObjectNode) | 780 if (!this._profile.fromFile() && selectedNode instanceof WebInspector.He
apSnapshotGenericObjectNode) |
780 ConsoleAgent.addInspectedHeapObject(selectedNode.snapshotNodeId); | 781 ConsoleAgent.addInspectedHeapObject(selectedNode.snapshotNodeId); |
781 }, | 782 }, |
782 | 783 |
783 /** | 784 /** |
(...skipping 1389 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2173 if (color) | 2174 if (color) |
2174 swatchDiv.style.backgroundColor = color; | 2175 swatchDiv.style.backgroundColor = color; |
2175 else | 2176 else |
2176 swatchDiv.classList.add("heap-snapshot-stats-empty-swatch"); | 2177 swatchDiv.classList.add("heap-snapshot-stats-empty-swatch"); |
2177 nameDiv.textContent = name; | 2178 nameDiv.textContent = name; |
2178 sizeDiv.textContent = WebInspector.UIString("%s KB", Number.withThousand
sSeparator(Math.round(value / 1024))); | 2179 sizeDiv.textContent = WebInspector.UIString("%s KB", Number.withThousand
sSeparator(Math.round(value / 1024))); |
2179 }, | 2180 }, |
2180 | 2181 |
2181 __proto__: WebInspector.VBox.prototype | 2182 __proto__: WebInspector.VBox.prototype |
2182 } | 2183 } |
OLD | NEW |