Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(18)

Side by Side Diff: Source/devtools/front_end/elements/ElementsPanel.js

Issue 352983004: DevTools: add more jsdocs to NetworkPanel. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 450 matching lines...) Expand 10 before | Expand all | Expand 10 after
461 }, 461 },
462 462
463 _populateContextMenu: function(contextMenu, node) 463 _populateContextMenu: function(contextMenu, node)
464 { 464 {
465 // Add debbuging-related actions 465 // Add debbuging-related actions
466 contextMenu.appendSeparator(); 466 contextMenu.appendSeparator();
467 var pane = WebInspector.domBreakpointsSidebarPane; 467 var pane = WebInspector.domBreakpointsSidebarPane;
468 pane.populateNodeContextMenu(node, contextMenu); 468 pane.populateNodeContextMenu(node, contextMenu);
469 }, 469 },
470 470
471 _getPopoverAnchor: function(element) 471 /**
472 * @param {!Element} element
473 * @param {!Event} event
474 * @return {!Element|!AnchorBox|undefined}
475 */
476 _getPopoverAnchor: function(element, event)
472 { 477 {
473 var anchor = element.enclosingNodeOrSelfWithClass("webkit-html-resource- link"); 478 var anchor = element.enclosingNodeOrSelfWithClass("webkit-html-resource- link");
474 if (!anchor || !anchor.href) 479 if (!anchor || !anchor.href)
475 return null; 480 return;
476 481
477 var treeOutlineElement = anchor.enclosingNodeOrSelfWithClass("elements-t ree-outline"); 482 var treeOutlineElement = anchor.enclosingNodeOrSelfWithClass("elements-t ree-outline");
478 if (!treeOutlineElement) 483 if (!treeOutlineElement)
479 return null; 484 return;
480 485
481 for (var i = 0; i < this._treeOutlines.length; ++i) { 486 for (var i = 0; i < this._treeOutlines.length; ++i) {
482 if (this._treeOutlines[i].element !== treeOutlineElement) 487 if (this._treeOutlines[i].element !== treeOutlineElement)
483 continue; 488 continue;
484 489
485 var resource = this._treeOutlines[i].target().resourceTreeModel.reso urceForURL(anchor.href); 490 var resource = this._treeOutlines[i].target().resourceTreeModel.reso urceForURL(anchor.href);
486 if (!resource || resource.type !== WebInspector.resourceTypes.Image) 491 if (!resource || resource.type !== WebInspector.resourceTypes.Image)
487 return null; 492 return;
488 anchor.removeAttribute("title"); 493 anchor.removeAttribute("title");
489 return anchor; 494 return anchor;
490 } 495 }
491 return null;
492 }, 496 },
493 497
494 /** 498 /**
495 * @param {!WebInspector.DOMNode} node 499 * @param {!WebInspector.DOMNode} node
496 * @param {function()} callback 500 * @param {function()} callback
497 */ 501 */
498 _loadDimensionsForNode: function(node, callback) 502 _loadDimensionsForNode: function(node, callback)
499 { 503 {
500 if (!node.nodeName() || node.nodeName().toLowerCase() !== "img") { 504 if (!node.nodeName() || node.nodeName().toLowerCase() !== "img") {
501 callback(); 505 callback();
(...skipping 969 matching lines...) Expand 10 before | Expand all | Expand 10 after
1471 /** 1475 /**
1472 * @suppressReceiverCheck 1476 * @suppressReceiverCheck
1473 * @this {Element} 1477 * @this {Element}
1474 */ 1478 */
1475 function parentElement() 1479 function parentElement()
1476 { 1480 {
1477 return this.parentElement; 1481 return this.parentElement;
1478 } 1482 }
1479 } 1483 }
1480 } 1484 }
OLDNEW
« no previous file with comments | « Source/devtools/front_end/components/ObjectPopoverHelper.js ('k') | Source/devtools/front_end/network/NetworkPanel.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698