Changeset 125966 in webkit
- Timestamp:
- Aug 18, 2012 2:32:33 AM (12 years ago)
- Location:
- trunk
- Files:
-
- 22 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r125965 r125966 1 2012-08-18 Pavel Feldman <pfeldman@chromium.org> 2 3 Web Inspector: make profiles panel a lazily loaded module. 4 https://bugs.webkit.org/show_bug.cgi?id=94351 5 6 Reviewed by Yury Semikhatsky. 7 8 * inspector/profiler/heap-snapshot-inspect-dom-wrapper.html: 9 * inspector/profiler/heap-snapshot-loader.html: 10 * inspector/profiler/heap-snapshot-summary-show-ranges.html: 11 * inspector/profiler/heap-snapshot-summary-shown-node-count-preserved-when-sorting.html: 12 1 13 2012-08-18 Pavel Feldman <pfeldman@chromium.org> 2 14 … … 22 34 * fast/forms/date/calendar-picker-appearance-pre-100-expected.txt: Added. 23 35 * fast/forms/date/calendar-picker-appearance-pre-100.html: Added. 36 37 2012-08-17 Dirk Pranke <dpranke@chromium.org> 38 39 Unreviewed, rolling out r125897. 40 http://trac.webkit.org/changeset/125897 41 https://bugs.webkit.org/show_bug.cgi?id=94326 42 43 This patch seems to have broken the inspector on the apple mac bots. 44 45 * http/tests/inspector/resource-tree/resource-tree-non-unique-url.html: 46 * inspector/database-table-name-excaping.html: 47 * inspector/styles/styles-invalid-color-values.html: 48 * inspector/timeline-dfs.html: 24 49 25 50 2012-08-17 Alice Cheng <alice_cheng@apple.com> -
trunk/LayoutTests/inspector/profiler/heap-snapshot-inspect-dom-wrapper.html
r125942 r125966 14 14 function test() 15 15 { 16 WebInspector.showPanel("profiles"); 16 17 ProfilerAgent.takeHeapSnapshot(step0); 17 18 -
trunk/LayoutTests/inspector/profiler/heap-snapshot-loader.html
r125942 r125966 12 12 } 13 13 14 WebInspector.showPanel("profiles"); 14 15 var source = InspectorTest.createHeapSnapshotMockRaw(); 15 16 var sourceStringified = JSON.stringify(source); -
trunk/LayoutTests/inspector/profiler/heap-snapshot-summary-show-ranges.html
r125942 r125966 7 7 function test() 8 8 { 9 WebInspector.showPanel("profiles"); 10 9 11 var instanceCount = 50; 10 12 function createHeapSnapshot() -
trunk/LayoutTests/inspector/profiler/heap-snapshot-summary-shown-node-count-preserved-when-sorting.html
r125942 r125966 7 7 function test() 8 8 { 9 WebInspector.showPanel("profiles"); 10 9 11 var instanceCount = 25; 10 12 function createHeapSnapshot() -
trunk/Source/WebCore/ChangeLog
r125965 r125966 1 2012-08-18 Pavel Feldman <pfeldman@chromium.org> 2 3 Web Inspector: make profiles panel a lazily loaded module. 4 https://bugs.webkit.org/show_bug.cgi?id=94351 5 6 Reviewed by Yury Semikhatsky. 7 8 - removed usages of WebInspector.panels.profiles. 9 - made panel lazily loaded 10 11 * WebCore.gypi: 12 * WebCore.xcodeproj/project.pbxproj: 13 * inspector/front-end/CPUProfileView.js: 14 (WebInspector.CPUProfileHeader.prototype.createView): 15 * inspector/front-end/CSSSelectorProfileView.js: 16 (WebInspector.CSSSelectorProfileType.prototype.buttonClicked): 17 (WebInspector.CSSSelectorProfileType.prototype._startRecordingProfile): 18 (WebInspector.CSSSelectorProfileType.prototype._stopRecordingProfile): 19 (WebInspector.CSSProfileHeader.prototype.createView): 20 * inspector/front-end/HeapSnapshotDataGrids.js: 21 (WebInspector.HeapSnapshotSortableDataGrid.prototype.populateContextMenu.revealInDominatorsView): 22 (WebInspector.HeapSnapshotSortableDataGrid.prototype.populateContextMenu.else.revealInSummaryView): 23 (WebInspector.HeapSnapshotSortableDataGrid.prototype.populateContextMenu): 24 * inspector/front-end/HeapSnapshotView.js: 25 (WebInspector.HeapSnapshotView.prototype._profiles): 26 (WebInspector.HeapSnapshotView.prototype.populateContextMenu): 27 (WebInspector.HeapSnapshotProfileType.prototype.buttonClicked): 28 (WebInspector.HeapProfileHeader.prototype.createView): 29 * inspector/front-end/InspectorFrontendAPI.js: 30 (InspectorFrontendAPI.isProfilingJavaScript): 31 (InspectorFrontendAPI.startProfilingJavaScript): 32 (InspectorFrontendAPI.stopProfilingJavaScript): 33 * inspector/front-end/NativeMemorySnapshotView.js: 34 (WebInspector.NativeMemoryProfileHeader.prototype.createView): 35 * inspector/front-end/ProfilesPanel.js: 36 (WebInspector.ProfileType.prototype.buttonClicked): 37 (WebInspector.ProfileHeader.prototype.view): 38 (WebInspector.ProfileHeader.prototype.createView): 39 (WebInspector.ProfilesPanel.prototype.toggleRecordButton): 40 (WebInspector.ProfilesPanel.prototype.showProfileForURL): 41 (WebInspector.RevealInHeapSnapshotContextMenuProvider.prototype.populateContextMenu.didReceiveHeapObjectId): 42 (WebInspector.RevealInHeapSnapshotContextMenuProvider.prototype.populateContextMenu): 43 (WebInspector.ProfileSidebarTreeElement.prototype.handleContextMenuEvent): 44 (WebInspector.ProfileGroupSidebarTreeElement.prototype.onselect): 45 * inspector/front-end/Settings.js: 46 * inspector/front-end/externs.js: 47 * inspector/front-end/inspector.html: 48 * inspector/front-end/inspector.js: 49 (WebInspector._panelDescriptors): 50 (WebInspector._toggleSearchingForNode): 51 (WebInspector._profilesLinkifier): 52 (WebInspector._requestZoom.set InspectorFrontendHost): 53 (WebInspector._requestZoom): 54 (WebInspector.documentClick.followLink): 55 (WebInspector.documentClick): 56 1 57 2012-08-18 Pavel Feldman <pfeldman@chromium.org> 2 58 … … 72 128 * platform/graphics/chromium/CompositorHUDFontAtlas.cpp: 73 129 (WebCore::CompositorHUDFontAtlas::generateFontAtlas): 130 131 2012-08-17 Dirk Pranke <dpranke@chromium.org> 132 133 Unreviewed, rolling out r125897. 134 http://trac.webkit.org/changeset/125897 135 https://bugs.webkit.org/show_bug.cgi?id=94326 136 137 This patch seems to have broken the inspector on the apple mac bots. 138 139 * WebCore.gypi: 140 * inspector/compile-front-end.py: 141 * inspector/front-end/AuditsPanel.js: 142 * inspector/front-end/CodeMirrorTextEditor.js: 143 (WebInspector.CodeMirrorTextEditor): 144 (WebInspector.CodeMirrorTextEditor.prototype._toRange): 145 (WebInspector.CodeMirrorTextEditor.prototype._loadLibraries.loadLibrary): 146 (WebInspector.CodeMirrorTextEditor.prototype._loadLibraries): 147 * inspector/front-end/Color.js: 148 * inspector/front-end/ElementsPanel.js: 149 * inspector/front-end/ExtensionServer.js: 150 (WebInspector.ExtensionServer.prototype._onCreatePanel): 151 * inspector/front-end/Panel.js: 152 (WebInspector.Panel): 153 (WebInspector.PanelDescriptor): 154 (WebInspector.PanelDescriptor.prototype.panel): 155 * inspector/front-end/ResourcesPanel.js: 156 * inspector/front-end/SettingsScreen.js: 157 (WebInspector.GenericSettingsTab): 158 * inspector/front-end/SourceFrame.js: 159 (WebInspector.SourceFrame): 160 * inspector/front-end/Spectrum.js: 161 (WebInspector.Spectrum.prototype.get outputColorFormat): 162 * inspector/front-end/StylesSidebarPane.js: 163 * inspector/front-end/TimelinePanel.js: 164 * inspector/front-end/inspector.html: 165 * inspector/front-end/inspector.js: 166 (WebInspector._panelDescriptors): 167 (WebInspector.doLoadedDone): 168 * inspector/front-end/utilities.js: 74 169 75 170 2012-08-17 Chris Rogers <crogers@google.com> -
trunk/Source/WebCore/WebCore.gypi
r125965 r125966 6256 6256 'inspector/front-end/AdvancedSearchController.js', 6257 6257 'inspector/front-end/ApplicationCacheModel.js', 6258 'inspector/front-end/BottomUpProfileDataGridTree.js',6259 6258 'inspector/front-end/BreakpointManager.js', 6260 6259 'inspector/front-end/BreakpointsSidebarPane.js', … … 6273 6272 'inspector/front-end/CookieParser.js', 6274 6273 'inspector/front-end/CookiesTable.js', 6275 'inspector/front-end/CPUProfileView.js',6276 6274 'inspector/front-end/CSSCompletions.js', 6277 6275 'inspector/front-end/CSSKeywordCompletions.js', 6278 'inspector/front-end/CSSSelectorProfileView.js',6279 6276 'inspector/front-end/CSSStyleModel.js', 6280 6277 'inspector/front-end/Database.js', … … 6307 6304 'inspector/front-end/HAREntry.js', 6308 6305 'inspector/front-end/HandlerRegistry.js', 6309 'inspector/front-end/HeapSnapshot.js',6310 'inspector/front-end/HeapSnapshotDataGrids.js',6311 'inspector/front-end/HeapSnapshotGridNodes.js',6312 'inspector/front-end/HeapSnapshotLoader.js',6313 'inspector/front-end/HeapSnapshotProxy.js',6314 'inspector/front-end/HeapSnapshotView.js',6315 6306 'inspector/front-end/HeapSnapshotWorker.js', 6316 'inspector/front-end/HeapSnapshotWorkerDispatcher.js',6317 6307 'inspector/front-end/HelpScreen.js', 6318 6308 'inspector/front-end/ImageView.js', … … 6330 6320 'inspector/front-end/KeyboardShortcut.js', 6331 6321 'inspector/front-end/Linkifier.js', 6332 'inspector/front-end/NativeMemorySnapshotView.js',6333 6322 'inspector/front-end/NavigatorOverlayController.js', 6334 6323 'inspector/front-end/NavigatorView.js', … … 6346 6335 'inspector/front-end/Popover.js', 6347 6336 'inspector/front-end/PresentationConsoleMessageHelper.js', 6348 'inspector/front-end/ProfileDataGridTree.js',6349 'inspector/front-end/ProfileLauncherView.js',6350 'inspector/front-end/ProfilesPanel.js',6351 6337 'inspector/front-end/ProgressBar.js', 6352 6338 'inspector/front-end/PropertiesSection.js', … … 6409 6395 'inspector/front-end/TimelineManager.js', 6410 6396 'inspector/front-end/Toolbar.js', 6411 'inspector/front-end/TopDownProfileDataGridTree.js',6412 6397 'inspector/front-end/treeoutline.js', 6413 6398 'inspector/front-end/UISourceCode.js', … … 6482 6467 'inspector/front-end/TimelinePanel.js', 6483 6468 ], 6469 6470 'webinspector_profiles_js_files': [ 6471 'inspector/front-end/BottomUpProfileDataGridTree.js', 6472 'inspector/front-end/CPUProfileView.js', 6473 'inspector/front-end/CSSSelectorProfileView.js', 6474 'inspector/front-end/HeapSnapshot.js', 6475 'inspector/front-end/HeapSnapshotDataGrids.js', 6476 'inspector/front-end/HeapSnapshotGridNodes.js', 6477 'inspector/front-end/HeapSnapshotLoader.js', 6478 'inspector/front-end/HeapSnapshotProxy.js', 6479 'inspector/front-end/HeapSnapshotView.js', 6480 'inspector/front-end/HeapSnapshotWorkerDispatcher.js', 6481 'inspector/front-end/NativeMemorySnapshotView.js', 6482 'inspector/front-end/ProfileDataGridTree.js', 6483 'inspector/front-end/ProfilesPanel.js', 6484 'inspector/front-end/ProfileLauncherView.js', 6485 'inspector/front-end/TopDownProfileDataGridTree.js', 6486 ], 6487 6484 6488 'webinspector_audits_js_files': [ 6485 6489 'inspector/front-end/AuditCategories.js', … … 6498 6502 'inspector/front-end/cm/xml.js', 6499 6503 ], 6504 6500 6505 'webinspector_modules_js_files': [ 6501 6506 '<@(webinspector_elements_js_files)', 6502 6507 '<@(webinspector_resources_js_files)', 6503 6508 '<@(webinspector_timeline_js_files)', 6509 '<@(webinspector_profiles_js_files)', 6504 6510 '<@(webinspector_audits_js_files)', 6505 6511 '<@(webinspector_codemirror_js_files)', -
trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj
r125965 r125966 25593 25593 "$(DERIVED_FILE_DIR)/WebCore/inspector.html", 25594 25594 "$(DERIVED_FILE_DIR)/WebCore/inspector.js", 25595 "$(DERIVED_FILE_DIR)/WebCore/scriptFormatterWorker.js", 25595 "$(DERIVED_FILE_DIR)/WebCore/ElementsPanel.js", 25596 "$(DERIVED_FILE_DIR)/WebCore/ResourcesPanel.js", 25597 "$(DERIVED_FILE_DIR)/WebCore/TimelinePanel.js", 25598 "$(DERIVED_FILE_DIR)/WebCore/ProfilesPanel.js", 25599 "$(DERIVED_FILE_DIR)/WebCore/AuditsPanel.js", 25600 "$(DERIVED_FILE_DIR)/WebCore/CodeMirrorTextEditor.js", 25601 "$(DERIVED_FILE_DIR)/WebCore/ScriptFormatterWorker.js", 25596 25602 ); 25597 25603 runOnlyForDeploymentPostprocessing = 0; 25598 25604 shellPath = /bin/sh; 25599 shellScript = "# Don't do anything for Debug builds, so the Inspector is easier to debug.\n# Don't do anything for Production builds, since the Inspector isn't installed.\nif [[ ${CONFIGURATION:=Debug} == \"Debug\" || ${CONFIGURATION:=Production} == \"Production\" ]]; then\n exit\nfi\n\n# Combine all script resources in the inspector.html file.\n\"$SRCROOT/inspector/combine-javascript-resources.pl\" --input-html \"${SRCROOT}/inspector/front-end/inspector.html\" --generated-scripts-dir \"${BUILT_PRODUCTS_DIR}/DerivedSources/WebCore\" --output-dir \"${DERIVED_FILE_DIR}/WebCore\" --output-script-name inspector.js\n\n# Inline script imports in ElementsPanel.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/ElementsPanel.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/ElementsPanel.js\"\n\n# Inline script imports in ResourcesPanel.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/ResourcesPanel.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/ResourcesPanel.js\"\n\n# Inline script imports in TimelinePanel.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/TimelinePanel.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/TimelinePanel.js\"\n\n# Inline script imports in AuditsPanel.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/AuditsPanel.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/AuditsPanel.js\"\n\n# Inline script imports in CodeMirrorTextEditor.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/CodeMirrorTextEditor.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/CodeMirrorTextEditor.js\"\n\n# Inline script imports in ScriptFormatterWorker.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/ScriptFormatterWorker.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/ScriptFormatterWorker.js\"\n\nif [ -d \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/inspector\" ]; then\n cd \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/inspector\"\n\n # Remove any top-level JavaScript files, since they will be replaced with the combined file.\n # Keep InspectorBackend*.js files so they can be used by other front-ends.\n find . -depth 1 -name \"*.js\" -not -name \"InspectorBackend*.js\" | xargs rm -rf\n\n # Copy the modified HTML file and the combined scripts.\n cp \"${DERIVED_FILE_DIR}/WebCore/inspector.html\" inspector.html\n cp \"${DERIVED_FILE_DIR}/WebCore/inspector.js\" inspector.js\n cp \"${DERIVED_FILE_DIR}/WebCore/ElementsPanel.js\" ElementsPanel.js\n cp \"${DERIVED_FILE_DIR}/WebCore/ResourcesPanel.js\" ResourcesPanel.js\n cp \"${DERIVED_FILE_DIR}/WebCore/TimelinePanel.js\" TimelinePanel.js\n cp \"${DERIVED_FILE_DIR}/WebCore/AuditsPanel.js\" AuditsPanel.js\n cp \"${DERIVED_FILE_DIR}/WebCore/CodeMirrorTextEditor.js\" CodeMirrorTextEditor.js\n cp \"${DERIVED_FILE_DIR}/WebCore/ScriptFormatterWorker.js\" ScriptFormatterWorker.js\nfi\n";25605 shellScript = "# Don't do anything for Debug builds, so the Inspector is easier to debug.\n# Don't do anything for Production builds, since the Inspector isn't installed.\nif [[ ${CONFIGURATION:=Debug} == \"Debug\" || ${CONFIGURATION:=Production} == \"Production\" ]]; then\n exit\nfi\n\n# Combine all script resources in the inspector.html file.\n\"$SRCROOT/inspector/combine-javascript-resources.pl\" --input-html \"${SRCROOT}/inspector/front-end/inspector.html\" --generated-scripts-dir \"${BUILT_PRODUCTS_DIR}/DerivedSources/WebCore\" --output-dir \"${DERIVED_FILE_DIR}/WebCore\" --output-script-name inspector.js\n\n# Inline script imports in ElementsPanel.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/ElementsPanel.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/ElementsPanel.js\"\n\n# Inline script imports in ResourcesPanel.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/ResourcesPanel.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/ResourcesPanel.js\"\n\n# Inline script imports in TimelinePanel.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/TimelinePanel.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/TimelinePanel.js\"\n\n# Inline script imports in ProfilesPanel.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/ProfilesPanel.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/ProfilesPanel.js\"\n\n# Inline script imports in AuditsPanel.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/AuditsPanel.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/AuditsPanel.js\"\n\n# Inline script imports in CodeMirrorTextEditor.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/CodeMirrorTextEditor.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/CodeMirrorTextEditor.js\"\n\n# Inline script imports in ScriptFormatterWorker.js file.\n\"$SRCROOT/inspector/inline-javascript-imports.py\" \"${SRCROOT}/inspector/front-end/ScriptFormatterWorker.js\" \"${SRCROOT}/inspector/front-end\" \"${DERIVED_FILE_DIR}/WebCore/ScriptFormatterWorker.js\"\n\nif [ -d \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/inspector\" ]; then\n cd \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/inspector\"\n\n # Remove any top-level JavaScript files, since they will be replaced with the combined file.\n # Keep InspectorBackend*.js files so they can be used by other front-ends.\n find . -depth 1 -name \"*.js\" -not -name \"InspectorBackend*.js\" | xargs rm -rf\n\n # Copy the modified HTML file and the combined scripts.\n cp \"${DERIVED_FILE_DIR}/WebCore/inspector.html\" inspector.html\n cp \"${DERIVED_FILE_DIR}/WebCore/inspector.js\" inspector.js\n cp \"${DERIVED_FILE_DIR}/WebCore/ElementsPanel.js\" ElementsPanel.js\n cp \"${DERIVED_FILE_DIR}/WebCore/ResourcesPanel.js\" ResourcesPanel.js\n cp \"${DERIVED_FILE_DIR}/WebCore/TimelinePanel.js\" TimelinePanel.js\n cp \"${DERIVED_FILE_DIR}/WebCore/ProfilesPanel.js\" ProfilesPanel.js\n cp \"${DERIVED_FILE_DIR}/WebCore/AuditsPanel.js\" AuditsPanel.js\n cp \"${DERIVED_FILE_DIR}/WebCore/CodeMirrorTextEditor.js\" CodeMirrorTextEditor.js\n cp \"${DERIVED_FILE_DIR}/WebCore/ScriptFormatterWorker.js\" ScriptFormatterWorker.js\nfi\n"; 25600 25606 }; 25601 25607 1C81BA330E97357C00266E07 /* Copy Inspector Resources */ = { -
trunk/Source/WebCore/inspector/InspectorProfilerAgent.cpp
r120456 r125966 322 322 void InspectorProfilerAgent::resetFrontendProfiles() 323 323 { 324 if (m_frontend 324 if (m_frontend && enabled() 325 325 && m_profiles.begin() == m_profiles.end() 326 326 && m_snapshots.begin() == m_snapshots.end()) -
trunk/Source/WebCore/inspector/front-end/CPUProfileView.js
r125942 r125966 651 651 /** 652 652 * @override 653 * @param {WebInspector.ProfilesPanel} profilesPanel 653 654 */ 654 createView: function( )655 createView: function(profilesPanel) 655 656 { 656 657 return new WebInspector.CPUProfileView(this); -
trunk/Source/WebCore/inspector/front-end/CSSSelectorProfileView.js
r125942 r125966 287 287 /** 288 288 * @override 289 * @param {WebInspector.ProfilesPanel} profilesPanel 289 290 * @return {boolean} 290 291 */ 291 buttonClicked: function( )292 buttonClicked: function(profilesPanel) 292 293 { 293 294 if (this._recording) { 294 this._stopRecordingProfile( );295 this._stopRecordingProfile(profilesPanel); 295 296 return false; 296 297 } else { 297 this._startRecordingProfile( );298 this._startRecordingProfile(profilesPanel); 298 299 return true; 299 300 } … … 320 321 }, 321 322 322 _startRecordingProfile: function() 323 /** 324 * @param {WebInspector.ProfilesPanel} profilesPanel 325 */ 326 _startRecordingProfile: function(profilesPanel) 323 327 { 324 328 this._recording = true; 325 329 CSSAgent.startSelectorProfiler(); 326 WebInspector.panels.profiles.setRecordingProfile(WebInspector.CSSSelectorProfileType.TypeId, true); 327 }, 328 329 _stopRecordingProfile: function() 330 profilesPanel.setRecordingProfile(WebInspector.CSSSelectorProfileType.TypeId, true); 331 }, 332 333 /** 334 * @param {WebInspector.ProfilesPanel} profilesPanel 335 */ 336 _stopRecordingProfile: function(profilesPanel) 330 337 { 331 338 /** … … 341 348 var title = WebInspector.UIString("Profile %d", uid) + String.sprintf(" (%s)", Number.secondsToString(profile.totalTime / 1000)); 342 349 var profileHeader = new WebInspector.CSSProfileHeader(this, title, uid, profile); 343 WebInspector.panels.profiles.addProfileHeader(profileHeader);344 WebInspector.panels.profiles.setRecordingProfile(WebInspector.CSSSelectorProfileType.TypeId, false);350 profilesPanel.addProfileHeader(profileHeader); 351 profilesPanel.setRecordingProfile(WebInspector.CSSSelectorProfileType.TypeId, false); 345 352 } 346 353 … … 389 396 /** 390 397 * @override 391 */ 392 createView: function() 398 * @param {WebInspector.ProfilesPanel} profilesPanel 399 */ 400 createView: function(profilesPanel) 393 401 { 394 402 var profile = /** @type {CSSAgent.SelectorProfile} */this._protocolData; -
trunk/Source/WebCore/inspector/front-end/HeapSnapshotDataGrids.js
r125942 r125966 98 98 99 99 /** 100 * @param {WebInspector.ProfilesPanel} profilesPanel 100 101 * @param {WebInspector.ContextMenu} contextMenu 101 */ 102 populateContextMenu: function(contextMenu, event) 102 * @param {Event} event 103 */ 104 populateContextMenu: function(profilesPanel, contextMenu, event) 103 105 { 104 106 var td = event.target.enclosingNodeOrSelfWithNodeName("td"); … … 109 111 function revealInDominatorsView() 110 112 { 111 WebInspector.panels.profiles.showObject(node.snapshotNodeId, "Dominators");113 profilesPanel.showObject(node.snapshotNodeId, "Dominators"); 112 114 } 113 115 contextMenu.appendItem(WebInspector.UIString("Reveal in Dominators View"), revealInDominatorsView.bind(this)); … … 115 117 function revealInSummaryView() 116 118 { 117 WebInspector.panels.profiles.showObject(node.snapshotNodeId, "Summary");119 profilesPanel.showObject(node.snapshotNodeId, "Summary"); 118 120 } 119 121 contextMenu.appendItem(WebInspector.UIString("Reveal in Summary View"), revealInSummaryView.bind(this)); -
trunk/Source/WebCore/inspector/front-end/HeapSnapshotView.js
r125942 r125966 32 32 * @constructor 33 33 * @extends {WebInspector.View} 34 * @param {WebInspector.ProfilesPanel} parent 34 35 */ 35 36 WebInspector.HeapSnapshotView = function(parent, profile) … … 408 409 _profiles: function() 409 410 { 410 return WebInspector.panels.profiles.getProfiles(WebInspector.HeapSnapshotProfileType.TypeId);411 return this.parent.getProfiles(WebInspector.HeapSnapshotProfileType.TypeId); 411 412 }, 412 413 … … 421 422 /** 422 423 * @param {WebInspector.ContextMenu} contextMenu 424 * @param {Event} event 423 425 */ 424 426 populateContextMenu: function(contextMenu, event) 425 427 { 426 this.dataGrid.populateContextMenu( contextMenu, event);428 this.dataGrid.populateContextMenu(this.parent, contextMenu, event); 427 429 }, 428 430 … … 721 723 WebInspector.HeapSnapshotView.prototype.__proto__ = WebInspector.View.prototype; 722 724 723 WebInspector.settings.showHeapSnapshotObjectsHiddenProperties = WebInspector.settings.createSetting("showHeaSnapshotObjectsHiddenProperties", false);724 725 725 /** 726 726 * @constructor … … 742 742 /** 743 743 * @override 744 * @param {WebInspector.ProfilesPanel} profilesPanel 744 745 * @return {boolean} 745 746 */ 746 buttonClicked: function( )747 { 748 WebInspector.panels.profiles.takeHeapSnapshot();747 buttonClicked: function(profilesPanel) 748 { 749 profilesPanel.takeHeapSnapshot(); 749 750 return false; 750 751 }, … … 847 848 /** 848 849 * @override 849 */ 850 createView: function() 851 { 852 return new WebInspector.HeapSnapshotView(WebInspector.panels.profiles, this); 850 * @param {WebInspector.ProfilesPanel} profilesPanel 851 */ 852 createView: function(profilesPanel) 853 { 854 return new WebInspector.HeapSnapshotView(profilesPanel, this); 853 855 }, 854 856 -
trunk/Source/WebCore/inspector/front-end/InspectorFrontendAPI.js
r125942 r125966 58 58 isProfilingJavaScript: function() 59 59 { 60 return WebInspector. CPUProfileType.instance && WebInspector.CPUProfileType.instance.isRecordingProfile();60 return WebInspector.panels.profiles && WebInspector.CPUProfileType.instance && WebInspector.CPUProfileType.instance.isRecordingProfile(); 61 61 }, 62 62 63 63 startProfilingJavaScript: function() 64 64 { 65 WebInspector.panels.profiles.enableProfiler(); 66 WebInspector.inspectorView.setCurrentPanel(WebInspector.panels.profiles); 65 WebInspector.showPanel("profiles").enableProfiler(); 67 66 if (WebInspector.CPUProfileType.instance) 68 67 WebInspector.CPUProfileType.instance.startRecordingProfile(); … … 71 70 stopProfilingJavaScript: function() 72 71 { 72 WebInspector.showPanel("profiles"); 73 73 if (WebInspector.CPUProfileType.instance) 74 74 WebInspector.CPUProfileType.instance.stopRecordingProfile(); 75 WebInspector.inspectorView.setCurrentPanel(WebInspector.panels.profiles);76 75 }, 77 76 -
trunk/Source/WebCore/inspector/front-end/NativeMemorySnapshotView.js
r125942 r125966 83 83 /** 84 84 * @override 85 * @param {WebInspector.ProfilesPanel} profilesPanel 85 86 * @return {boolean} 86 87 */ 87 buttonClicked: function() 88 { 89 var profilesPanel = WebInspector.panels.profiles; 88 buttonClicked: function(profilesPanel) 89 { 90 90 var profileHeader = new WebInspector.NativeMemoryProfileHeader(this, WebInspector.UIString("Snapshot %d", this._nextProfileUid), this._nextProfileUid); 91 91 ++this._nextProfileUid; … … 179 179 /** 180 180 * @override 181 */ 182 createView: function() 181 * @param {WebInspector.ProfilesPanel} profilesPanel 182 */ 183 createView: function(profilesPanel) 183 184 { 184 185 return new WebInspector.NativeMemorySnapshotView(this); -
trunk/Source/WebCore/inspector/front-end/ProfilesPanel.js
r125942 r125966 39 39 } 40 40 41 WebInspector.ProfileType.URLRegExp = /webkit-profile:\/\/(.+)\/(.+)#([0-9]+)/;42 43 41 WebInspector.ProfileType.prototype = { 44 42 get buttonTooltip() … … 63 61 64 62 /** 63 * @param {WebInspector.ProfilesPanel} profilesPanel 65 64 * @return {boolean} 66 65 */ 67 buttonClicked: function( )66 buttonClicked: function(profilesPanel) 68 67 { 69 68 return false; … … 98 97 } 99 98 } 100 101 WebInspector.registerLinkifierPlugin(function(title)102 {103 var profileStringMatches = WebInspector.ProfileType.URLRegExp.exec(title);104 if (profileStringMatches)105 title = WebInspector.panels.profiles.displayTitleForProfileLink(profileStringMatches[2], profileStringMatches[1]);106 return title;107 });108 99 109 100 /** … … 150 141 { 151 142 if (!this._view) 152 this._view = this.createView( );143 this._view = this.createView(WebInspector.ProfilesPanel._instance); 153 144 return this._view; 154 145 }, 155 146 156 createView: function() 147 /** 148 * @param {WebInspector.ProfilesPanel} profilesPanel 149 */ 150 createView: function(profilesPanel) 157 151 { 158 152 throw new Error("Not implemented."); … … 194 188 { 195 189 WebInspector.Panel.call(this, "profiles"); 190 WebInspector.ProfilesPanel._instance = this; 196 191 this.registerRequiredCSS("panelEnablerView.css"); 197 192 this.registerRequiredCSS("heapProfiler.css"); … … 256 251 InspectorBackend.registerProfilerDispatcher(new WebInspector.ProfilerDispatcher(this)); 257 252 258 if (!Capabilities.profilerCausesRecompilation || WebInspector.settings.profilerEnabled.get())259 ProfilerAgent.enable(this._profilerWasEnabled.bind(this));260 261 253 this._createFileSelectorElement(); 262 254 this.element.addEventListener("contextmenu", this._handleContextMenuEvent.bind(this), true); … … 302 294 toggleRecordButton: function() 303 295 { 304 var isProfiling = this._selectedProfileType.buttonClicked( );296 var isProfiling = this._selectedProfileType.buttonClicked(this); 305 297 this.recordButton.toggled = isProfiling; 306 298 this.recordButton.title = this._selectedProfileType.buttonTooltip; … … 701 693 showProfileForURL: function(url) 702 694 { 703 var match = url.match(WebInspector.Profile Type.URLRegExp);695 var match = url.match(WebInspector.ProfileURLRegExp); 704 696 if (!match) 705 697 return; … … 1105 1097 populateContextMenu: function(section, contextMenu) 1106 1098 { 1107 if (WebInspector.inspectorView.currentPanel() !== WebInspector. panels.profiles)1099 if (WebInspector.inspectorView.currentPanel() !== WebInspector.ProfilesPanel._instance) 1108 1100 return; 1109 1101 … … 1112 1104 return; 1113 1105 1114 var heapProfiles = WebInspector. panels.profiles.getProfiles(WebInspector.HeapSnapshotProfileType.TypeId);1106 var heapProfiles = WebInspector.ProfilesPanel._instance.getProfiles(WebInspector.HeapSnapshotProfileType.TypeId); 1115 1107 if (!heapProfiles.length) 1116 1108 return; … … 1123 1115 function didReceiveHeapObjectId(viewName, error, result) 1124 1116 { 1125 if (WebInspector.inspectorView.currentPanel() !== WebInspector. panels.profiles)1117 if (WebInspector.inspectorView.currentPanel() !== WebInspector.ProfilesPanel._instance) 1126 1118 return; 1127 1119 if (!error) 1128 WebInspector. panels.profiles.showObject(result, viewName);1120 WebInspector.ProfilesPanel._instance.showObject(result, viewName); 1129 1121 } 1130 1122 … … 1266 1258 if (profile.canSaveToFile()) 1267 1259 contextMenu.appendItem(WebInspector.UIString("Save profile\u2026"), profile.saveToFile.bind(profile)); 1268 contextMenu.appendItem(WebInspector.UIString("Load profile\u2026"), WebInspector.panels.profiles._fileSelectorElement.click.bind(WebInspector.panels.profiles._fileSelectorElement)); 1260 // FIXME: use context menu provider 1261 var profilesPanel = WebInspector.ProfilesPanel._instance; 1262 contextMenu.appendItem(WebInspector.UIString("Load profile\u2026"), profilesPanel._fileSelectorElement.click.bind(profilesPanel._fileSelectorElement)); 1269 1263 contextMenu.appendItem(WebInspector.UIString("Delete profile"), this.ondelete.bind(this)); 1270 1264 contextMenu.show(event); … … 1289 1283 { 1290 1284 if (this.children.length > 0) 1291 WebInspector. panels.profiles.showProfile(this.children[this.children.length - 1].profile);1285 WebInspector.ProfilesPanel._instance.showProfile(this.children[this.children.length - 1].profile); 1292 1286 } 1293 1287 } … … 1320 1314 1321 1315 WebInspector.ProfilesSidebarTreeElement.prototype.__proto__ = WebInspector.SidebarTreeElement.prototype; 1316 1317 importScript("ProfileDataGridTree.js"); 1318 importScript("BottomUpProfileDataGridTree.js"); 1319 importScript("CPUProfileView.js"); 1320 importScript("CSSSelectorProfileView.js"); 1321 importScript("HeapSnapshot.js"); 1322 importScript("HeapSnapshotDataGrids.js"); 1323 importScript("HeapSnapshotGridNodes.js"); 1324 importScript("HeapSnapshotLoader.js"); 1325 importScript("HeapSnapshotProxy.js"); 1326 importScript("HeapSnapshotView.js"); 1327 importScript("HeapSnapshotWorkerDispatcher.js"); 1328 importScript("NativeMemorySnapshotView.js"); 1329 importScript("ProfileLauncherView.js"); 1330 importScript("TopDownProfileDataGridTree.js"); -
trunk/Source/WebCore/inspector/front-end/Settings.js
r125942 r125966 43 43 exposeDisableCache: false, 44 44 applicationTitle: "Web Inspector - %s", 45 showHeapSnapshotObjectsHiddenProperties: false,46 45 showDockToRight: false, 47 46 exposeFileSystemInspection: false … … 102 101 this.geolocationOverride = this.createSetting("geolocationOverride", ""); 103 102 this.deviceOrientationOverride = this.createSetting("deviceOrientationOverride", ""); 103 this.showHeapSnapshotObjectsHiddenProperties = this.createSetting("showHeaSnapshotObjectsHiddenProperties", false); 104 104 105 105 // If there are too many breakpoints in a storage, it is likely due to a recent bug that caused -
trunk/Source/WebCore/inspector/front-end/externs.js
r125942 r125966 247 247 /** @constructor */ 248 248 WebInspector.CodeMirrorTextEditor = function(url, delegate) { } 249 250 WebInspector.ProfileURLRegExp = ""; -
trunk/Source/WebCore/inspector/front-end/inspector.html
r125965 r125966 122 122 <script type="text/javascript" src="RevisionHistoryView.js"></script> 123 123 <script type="text/javascript" src="ScriptsNavigator.js"></script> 124 <script type="text/javascript" src="ProfilesPanel.js"></script>125 124 <script type="text/javascript" src="ConsolePanel.js"></script> 126 125 <script type="text/javascript" src="ExtensionAPI.js"></script> … … 151 150 <script type="text/javascript" src="FontView.js"></script> 152 151 <script type="text/javascript" src="ImageView.js"></script> 153 <script type="text/javascript" src="ProfileLauncherView.js"></script>154 <script type="text/javascript" src="ProfileDataGridTree.js"></script>155 <script type="text/javascript" src="BottomUpProfileDataGridTree.js"></script>156 <script type="text/javascript" src="TopDownProfileDataGridTree.js"></script>157 <script type="text/javascript" src="CPUProfileView.js"></script>158 <script type="text/javascript" src="CSSSelectorProfileView.js"></script>159 <script type="text/javascript" src="HeapSnapshot.js"></script>160 <script type="text/javascript" src="HeapSnapshotProxy.js"></script>161 <script type="text/javascript" src="HeapSnapshotWorkerDispatcher.js"></script>162 <script type="text/javascript" src="HeapSnapshotGridNodes.js"></script>163 <script type="text/javascript" src="HeapSnapshotLoader.js"></script>164 <script type="text/javascript" src="HeapSnapshotDataGrids.js"></script>165 <script type="text/javascript" src="HeapSnapshotView.js"></script>166 <script type="text/javascript" src="NativeMemorySnapshotView.js"></script>167 152 <script type="text/javascript" src="DebuggerModel.js"></script> 168 153 <script type="text/javascript" src="SourceMapping.js"></script> -
trunk/Source/WebCore/inspector/front-end/inspector.js
r125965 r125966 43 43 var scripts = new WebInspector.PanelDescriptor("scripts", WebInspector.UIString("Sources"), undefined, undefined, new WebInspector.ScriptsPanel()); 44 44 var timeline = new WebInspector.PanelDescriptor("timeline", WebInspector.UIString("Timeline"), "TimelinePanel", "TimelinePanel.js"); 45 var profiles = new WebInspector.PanelDescriptor("profiles", WebInspector.UIString("Profiles"), undefined, undefined, new WebInspector.ProfilesPanel());45 var profiles = new WebInspector.PanelDescriptor("profiles", WebInspector.UIString("Profiles"), "ProfilesPanel", "ProfilesPanel.js"); 46 46 var audits = new WebInspector.PanelDescriptor("audits", WebInspector.UIString("Audits"), "AuditsPanel", "AuditsPanel.js"); 47 47 var console = new WebInspector.PanelDescriptor("console", WebInspector.UIString("Console"), "ConsolePanel"); … … 385 385 } 386 386 WebInspector.domAgent.setInspectModeEnabled(enabled, callback.bind(this)); 387 }, 388 389 _profilesLinkifier: function(title) 390 { 391 var profileStringMatches = WebInspector.ProfileURLRegExp.exec(title); 392 if (profileStringMatches) { 393 var profilesPanel = /** @ type {WebInspector.ProfilesPanel} */ WebInspector.panel("profiles"); 394 title = WebInspector.ProfilesPanel._instance.displayTitleForProfileLink(profileStringMatches[2], profileStringMatches[1]); 395 } 396 return title; 387 397 } 388 398 } … … 528 538 529 539 this.addMainEventListeners(document); 540 WebInspector.registerLinkifierPlugin(this._profilesLinkifier.bind(this)); 530 541 531 542 window.addEventListener("resize", this.windowResize.bind(this), true); … … 548 559 DatabaseAgent.enable(); 549 560 DOMStorageAgent.enable(); 561 if (!Capabilities.profilerCausesRecompilation || WebInspector.settings.profilerEnabled.get()) 562 ProfilerAgent.enable(); 550 563 551 564 if (WebInspector.settings.showPaintRects.get()) … … 672 685 return; 673 686 674 const profileMatch = WebInspector.Profile Type.URLRegExp.exec(anchor.href);687 const profileMatch = WebInspector.ProfileURLRegExp.exec(anchor.href); 675 688 if (profileMatch) { 676 689 WebInspector.showProfileForURL(anchor.href); … … 1077 1090 this.resourceTreeModel.frontendReused(); 1078 1091 } 1092 1093 WebInspector.ProfileURLRegExp = /webkit-profile:\/\/(.+)\/(.+)#([0-9]+)/; -
trunk/Source/WebKit/chromium/ChangeLog
r125965 r125966 1 2012-08-18 Pavel Feldman <pfeldman@chromium.org> 2 3 Web Inspector: make profiles panel a lazily loaded module. 4 https://bugs.webkit.org/show_bug.cgi?id=94351 5 6 Reviewed by Yury Semikhatsky. 7 8 * WebKit.gyp: 9 1 10 2012-08-18 Pavel Feldman <pfeldman@chromium.org> 2 11 … … 5 14 6 15 Reviewed by Vsevolod Vlasov. 16 17 * WebKit.gyp: 18 * scripts/concatenate_js_files.py: 19 (OrderedJSFilesExtractor.handle_starttag): 20 * scripts/inline_js_imports.py: 21 (main): 22 23 2012-08-17 Dirk Pranke <dpranke@chromium.org> 24 25 Unreviewed, rolling out r125897. 26 http://trac.webkit.org/changeset/125897 27 https://bugs.webkit.org/show_bug.cgi?id=94326 28 29 this patch seems to have broken the inspector on the apple mac bots. 7 30 8 31 * WebKit.gyp: -
trunk/Source/WebKit/chromium/WebKit.gyp
r125965 r125966 877 877 'concatenated_devtools_resources_js', 878 878 'concatenated_devtools_timeline_js', 879 'concatenated_devtools_profiles_js', 879 880 'concatenated_devtools_audits_js', 880 881 'concatenated_devtools_codemirror_js', … … 962 963 'concatenated_devtools_resources_js', 963 964 'concatenated_devtools_timeline_js', 965 'concatenated_devtools_profiles_js', 964 966 'concatenated_devtools_audits_js', 965 967 'concatenated_devtools_codemirror_js', … … 983 985 '<(PRODUCT_DIR)/resources/inspector/ResourcesPanel.js', 984 986 '<(PRODUCT_DIR)/resources/inspector/TimelinePanel.js', 987 '<(PRODUCT_DIR)/resources/inspector/ProfilesPanel.js', 985 988 '<(PRODUCT_DIR)/resources/inspector/AuditsPanel.js', 986 989 '<(PRODUCT_DIR)/resources/inspector/CodeMirrorTextEditor.js', … … 1154 1157 }, 1155 1158 { 1159 'target_name': 'concatenated_devtools_profiles_js', 1160 'type': 'none', 1161 'actions': [{ 1162 'action_name': 'concatenate_devtools_profiles_js', 1163 'script_name': 'scripts/inline_js_imports.py', 1164 'input_file': '../../WebCore/inspector/front-end/ProfilesPanel.js', 1165 'inputs': [ 1166 '<@(_script_name)', 1167 '<@(webinspector_profiles_js_files)', 1168 ], 1169 'search_path': '../../WebCore/inspector/front-end', 1170 'outputs': ['<(PRODUCT_DIR)/resources/inspector/ProfilesPanel.js'], 1171 'action': ['python', '<@(_script_name)', '<@(_input_file)', '<@(_search_path)', '<@(_outputs)'], 1172 }], 1173 }, 1174 { 1156 1175 'target_name': 'concatenated_devtools_audits_js', 1157 1176 'type': 'none',
Note: See TracChangeset
for help on using the changeset viewer.