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 554 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
565 offsetHeight: this.offsetHeight, | 565 offsetHeight: this.offsetHeight, |
566 naturalWidth: this.naturalWidth, | 566 naturalWidth: this.naturalWidth, |
567 naturalHeight: this.naturalHeight, | 567 naturalHeight: this.naturalHeight, |
568 currentSrc: this.currentSrc | 568 currentSrc: this.currentSrc |
569 }; | 569 }; |
570 } | 570 } |
571 } | 571 } |
572 } | 572 } |
573 | 573 |
574 /** | 574 /** |
575 * @param {!Element} link | 575 * @param {!Element|!AnchorBox} link |
576 * @param {!UI.GlassPane} popover | 576 * @param {!UI.GlassPane} popover |
577 * @return {!Promise<boolean>} | 577 * @return {!Promise<boolean>} |
578 */ | 578 */ |
579 _showPopover(link, popover) { | 579 _showPopover(link, popover) { |
580 var fulfill; | 580 var fulfill; |
581 var promise = new Promise(x => fulfill = x); | 581 var promise = new Promise(x => fulfill = x); |
582 var listItem = link.enclosingNodeOrSelfWithNodeName('li'); | 582 var listItem = link.enclosingNodeOrSelfWithNodeName('li'); |
583 var node = /** @type {!Elements.ElementsTreeElement} */ (listItem.treeElemen
t).node(); | 583 var node = /** @type {!Elements.ElementsTreeElement} */ (listItem.treeElemen
t).node(); |
584 this._loadDimensionsForNode( | 584 this._loadDimensionsForNode( |
585 node, Components.DOMPresentationUtils.buildImagePreviewContents.bind( | 585 node, Components.DOMPresentationUtils.buildImagePreviewContents.bind( |
(...skipping 1107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1693 */ | 1693 */ |
1694 function resolved(node) { | 1694 function resolved(node) { |
1695 if (node) { | 1695 if (node) { |
1696 this.treeOutline._selectedDOMNode = node; | 1696 this.treeOutline._selectedDOMNode = node; |
1697 this.treeOutline._selectedNodeChanged(); | 1697 this.treeOutline._selectedNodeChanged(); |
1698 } | 1698 } |
1699 } | 1699 } |
1700 return true; | 1700 return true; |
1701 } | 1701 } |
1702 }; | 1702 }; |
OLD | NEW |