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

Side by Side Diff: chrome/browser/ui/webui/profiler_ui.cc

Issue 8588023: Collect profiler stats from browser child processes. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/webui/profiler_ui.h" 5 #include "chrome/browser/ui/webui/profiler_ui.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 // When testing the javacript code, it is cumbersome to have to keep 9 // When testing the javacript code, it is cumbersome to have to keep
10 // re-building the resouces package and reloading the browser. To solve 10 // re-building the resouces package and reloading the browser. To solve
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 154
155 // Set up the chrome://profiler/ source. 155 // Set up the chrome://profiler/ source.
156 Profile::FromBrowserContext(contents->browser_context())-> 156 Profile::FromBrowserContext(contents->browser_context())->
157 GetChromeURLDataManager()->AddDataSource(CreateProfilerHTMLSource()); 157 GetChromeURLDataManager()->AddDataSource(CreateProfilerHTMLSource());
158 } 158 }
159 159
160 ProfilerUI::~ProfilerUI() { 160 ProfilerUI::~ProfilerUI() {
161 } 161 }
162 162
163 void ProfilerUI::GetData() { 163 void ProfilerUI::GetData() {
164 TrackingSynchronizer::FetchTrackingDataAsynchronously(ui_weak_ptr_); 164 TrackingSynchronizer::FetchProfilerDataAsynchronously(ui_weak_ptr_);
165 } 165 }
166 166
167 void ProfilerUI::ReceivedData(base::Value* value) { 167 void ProfilerUI::ReceivedData(base::Value* value) {
168 // Send the data to the renderer. 168 // Send the data to the renderer.
169 scoped_ptr<Value> data_values(value); 169 scoped_ptr<Value> data_values(value);
170 CallJavascriptFunction("g_browserBridge.receivedData", *data_values.get()); 170 CallJavascriptFunction("g_browserBridge.receivedData", *data_values.get());
171 } 171 }
172 172
OLDNEW
« no previous file with comments | « chrome/browser/renderer_host/chrome_render_message_filter.cc ('k') | chrome/browser/ui/webui/tracking_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698