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) 2008 Matt Lilek <webkit@mattlilek.com> | 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> |
4 * Copyright (C) 2009 Joseph Pecoraro | 4 * Copyright (C) 2009 Joseph Pecoraro |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * | 9 * |
10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
(...skipping 332 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
343 | 343 |
344 /** | 344 /** |
345 * @param {?WebInspector.DOMNode} node | 345 * @param {?WebInspector.DOMNode} node |
346 * @param {boolean} omitFocus | 346 * @param {boolean} omitFocus |
347 */ | 347 */ |
348 _revealAndSelectNode: function(node, omitFocus) | 348 _revealAndSelectNode: function(node, omitFocus) |
349 { | 349 { |
350 if (this._suppressRevealAndSelect) | 350 if (this._suppressRevealAndSelect) |
351 return; | 351 return; |
352 | 352 |
| 353 this._updateModifiedNodes(); |
| 354 |
353 if (!this._includeRootDOMNode && node === this.rootDOMNode && this.rootD
OMNode) | 355 if (!this._includeRootDOMNode && node === this.rootDOMNode && this.rootD
OMNode) |
354 node = this.rootDOMNode.firstChild; | 356 node = this.rootDOMNode.firstChild; |
355 if (!node) | 357 if (!node) |
356 return; | 358 return; |
357 var treeElement = this.createTreeElementFor(node); | 359 var treeElement = this.createTreeElementFor(node); |
358 if (!treeElement) | 360 if (!treeElement) |
359 return; | 361 return; |
360 | 362 |
361 treeElement.revealAndSelect(omitFocus); | 363 treeElement.revealAndSelect(omitFocus); |
362 }, | 364 }, |
(...skipping 550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
913 // Preserve the semantic of node by following the order of updates for h
ide and show. | 915 // Preserve the semantic of node by following the order of updates for h
ide and show. |
914 if (show) { | 916 if (show) { |
915 for (var i = 0, size = this._highlightResult.length; i < size; ++i) | 917 for (var i = 0, size = this._highlightResult.length; i < size; ++i) |
916 updateEntryShow(this._highlightResult[i]); | 918 updateEntryShow(this._highlightResult[i]); |
917 } else { | 919 } else { |
918 for (var i = (this._highlightResult.length - 1); i >= 0; --i) | 920 for (var i = (this._highlightResult.length - 1); i >= 0; --i) |
919 updateEntryHide(this._highlightResult[i]); | 921 updateEntryHide(this._highlightResult[i]); |
920 } | 922 } |
921 }, | 923 }, |
922 | 924 |
| 925 /** |
| 926 * @param {boolean} inClipboard |
| 927 */ |
| 928 setInClipboard: function(inClipboard) |
| 929 { |
| 930 if (this._inClipboard === inClipboard) |
| 931 return; |
| 932 this._inClipboard = inClipboard; |
| 933 this.listItemElement.classList.toggle("in-clipboard", inClipboard); |
| 934 }, |
| 935 |
923 get hovered() | 936 get hovered() |
924 { | 937 { |
925 return this._hovered; | 938 return this._hovered; |
926 }, | 939 }, |
927 | 940 |
928 set hovered(x) | 941 set hovered(x) |
929 { | 942 { |
930 if (this._hovered === x) | 943 if (this._hovered === x) |
931 return; | 944 return; |
932 | 945 |
(...skipping 1738 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2671 var treeOutline = new WebInspector.ElementsTreeOutline(node.target(), fa
lse, false); | 2684 var treeOutline = new WebInspector.ElementsTreeOutline(node.target(), fa
lse, false); |
2672 treeOutline.rootDOMNode = node; | 2685 treeOutline.rootDOMNode = node; |
2673 treeOutline.element.classList.add("outline-disclosure"); | 2686 treeOutline.element.classList.add("outline-disclosure"); |
2674 if (!treeOutline.children[0].hasChildren) | 2687 if (!treeOutline.children[0].hasChildren) |
2675 treeOutline.element.classList.add("single-node"); | 2688 treeOutline.element.classList.add("single-node"); |
2676 treeOutline.setVisible(true); | 2689 treeOutline.setVisible(true); |
2677 treeOutline.element.treeElementForTest = treeOutline.children[0]; | 2690 treeOutline.element.treeElementForTest = treeOutline.children[0]; |
2678 return treeOutline.element; | 2691 return treeOutline.element; |
2679 } | 2692 } |
2680 } | 2693 } |
OLD | NEW |