| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 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 25 matching lines...) Expand all Loading... |
| 36 { | 36 { |
| 37 WebInspector.PanelWithSidebar.call(this, "audits"); | 37 WebInspector.PanelWithSidebar.call(this, "audits"); |
| 38 this.registerRequiredCSS("ui/panelEnablerView.css"); | 38 this.registerRequiredCSS("ui/panelEnablerView.css"); |
| 39 this.registerRequiredCSS("audits/auditsPanel.css"); | 39 this.registerRequiredCSS("audits/auditsPanel.css"); |
| 40 | 40 |
| 41 var sidebarTree = new TreeOutline(); | 41 var sidebarTree = new TreeOutline(); |
| 42 sidebarTree.element.classList.add("sidebar-tree"); | 42 sidebarTree.element.classList.add("sidebar-tree"); |
| 43 this.panelSidebarElement().appendChild(sidebarTree.element); | 43 this.panelSidebarElement().appendChild(sidebarTree.element); |
| 44 this.setDefaultFocusedElement(sidebarTree.element); | 44 this.setDefaultFocusedElement(sidebarTree.element); |
| 45 | 45 |
| 46 this.auditsTreeElement = new WebInspector.SidebarSectionTreeElement("", true
); | 46 this.auditsTreeElement = new WebInspector.SidebarSectionTreeElement(""); |
| 47 sidebarTree.appendChild(this.auditsTreeElement); | 47 sidebarTree.appendChild(this.auditsTreeElement); |
| 48 this.auditsTreeElement.listItemElement.classList.add("hidden"); | 48 this.auditsTreeElement.listItemElement.classList.add("hidden"); |
| 49 | 49 |
| 50 this.auditsItemTreeElement = new WebInspector.AuditsSidebarTreeElement(this)
; | 50 this.auditsItemTreeElement = new WebInspector.AuditsSidebarTreeElement(this)
; |
| 51 this.auditsTreeElement.appendChild(this.auditsItemTreeElement); | 51 this.auditsTreeElement.appendChild(this.auditsItemTreeElement); |
| 52 | 52 |
| 53 this.auditResultsTreeElement = new WebInspector.SidebarSectionTreeElement(We
bInspector.UIString("RESULTS"), true); | 53 this.auditResultsTreeElement = new WebInspector.SidebarSectionTreeElement(We
bInspector.UIString("RESULTS")); |
| 54 sidebarTree.appendChild(this.auditResultsTreeElement); | 54 sidebarTree.appendChild(this.auditResultsTreeElement); |
| 55 this.auditResultsTreeElement.expand(); | 55 this.auditResultsTreeElement.expand(); |
| 56 | 56 |
| 57 this._constructCategories(); | 57 this._constructCategories(); |
| 58 | 58 |
| 59 this._auditController = new WebInspector.AuditController(this); | 59 this._auditController = new WebInspector.AuditController(this); |
| 60 this._launcherView = new WebInspector.AuditLauncherView(this._auditControlle
r); | 60 this._launcherView = new WebInspector.AuditLauncherView(this._auditControlle
r); |
| 61 for (var id in this.categoriesById) | 61 for (var id in this.categoriesById) |
| 62 this._launcherView.addCategory(this.categoriesById[id]); | 62 this._launcherView.addCategory(this.categoriesById[id]); |
| 63 | 63 |
| (...skipping 511 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 575 } | 575 } |
| 576 | 576 |
| 577 // Contributed audit rules should go into this namespace. | 577 // Contributed audit rules should go into this namespace. |
| 578 WebInspector.AuditRules = {}; | 578 WebInspector.AuditRules = {}; |
| 579 | 579 |
| 580 /** | 580 /** |
| 581 * Contributed audit categories should go into this namespace. | 581 * Contributed audit categories should go into this namespace. |
| 582 * @type {!Object.<string, function(new:WebInspector.AuditCategory)>} | 582 * @type {!Object.<string, function(new:WebInspector.AuditCategory)>} |
| 583 */ | 583 */ |
| 584 WebInspector.AuditCategories = {}; | 584 WebInspector.AuditCategories = {}; |
| OLD | NEW |