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

Unified Diff: webkit/glue/devtools/js/debugger_agent.js

Issue 118112: DevTools Profiler UI changes.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | webkit/glue/devtools/js/devtools.js » ('j') | webkit/glue/devtools/js/profiler_processor.js » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/devtools/js/debugger_agent.js
===================================================================
--- webkit/glue/devtools/js/debugger_agent.js (revision 17398)
+++ webkit/glue/devtools/js/debugger_agent.js (working copy)
@@ -611,6 +611,22 @@
if (is_started && !this.isProfilingStarted_) {
// Start to query log data.
RemoteDebuggerAgent.GetLogLines(this.lastProfileLogPosition_);
+ } else if (!is_started && this.isProfilingStarted_) {
+ // Display a temporary icon / message indicating that the profile
+ // is being processed.
+ var processingIcon = new WebInspector.SidebarTreeElement(
+ "profile-sidebar-tree-item", "Processing...", "", null, false);
+ var profilesSidebar = WebInspector.panels.profiles.sidebarTree;
+ profilesSidebar.appendChild(processingIcon);
+ var profilerProcessor = this.profilerProcessor_;
+ // Set a callback for adding a profile that removes the temporary element
+ // and restores plain "addProfile" callback.
+ profilerProcessor.setNewProfileCallback(function (profile) {
+ profilesSidebar.removeChild(processingIcon);
+ WebInspector.addProfile(profile);
+ profilerProcessor.setNewProfileCallback(
+ goog.bind(WebInspector.addProfile, WebInspector));
+ });
}
this.isProfilingStarted_ = is_started;
// Update button.
« no previous file with comments | « no previous file | webkit/glue/devtools/js/devtools.js » ('j') | webkit/glue/devtools/js/profiler_processor.js » ('J')

Powered by Google App Engine
This is Rietveld 408576698