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

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

Issue 7554008: Removal of Profile from content part 6. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Profile helper function, rebase Created 9 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « chrome/browser/ui/webui/active_downloads_ui.cc ('k') | chrome/browser/ui/webui/chrome_web_ui.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/bug_report_ui.h" 5 #include "chrome/browser/ui/webui/bug_report_ui.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 524 matching lines...) Expand 10 before | Expand all | Expand 10 after
535 std::string sys_info_checkbox; 535 std::string sys_info_checkbox;
536 (*i)->GetAsString(&sys_info_checkbox); 536 (*i)->GetAsString(&sys_info_checkbox);
537 bool send_sys_info = (sys_info_checkbox == "true"); 537 bool send_sys_info = (sys_info_checkbox == "true");
538 538
539 // If we aren't sending the sys_info, cancel the gathering of the syslogs. 539 // If we aren't sending the sys_info, cancel the gathering of the syslogs.
540 if (!send_sys_info) 540 if (!send_sys_info)
541 CancelFeedbackCollection(); 541 CancelFeedbackCollection();
542 #endif 542 #endif
543 543
544 // Update the data in bug_report_data_ so it can be sent 544 // Update the data in bug_report_data_ so it can be sent
545 bug_report_data_->UpdateData(web_ui_->GetProfile() 545 bug_report_data_->UpdateData(Profile::FromWebUI(web_ui_)
546 , target_tab_url_ 546 , target_tab_url_
547 , problem_type 547 , problem_type
548 , page_url 548 , page_url
549 , description 549 , description
550 , image 550 , image
551 #if defined(OS_CHROMEOS) 551 #if defined(OS_CHROMEOS)
552 , user_email 552 , user_email
553 , send_sys_info 553 , send_sys_info
554 , false // sent_report 554 , false // sent_report
555 #endif 555 #endif
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
618 AddMessageHandler((handler)->Attach(this)); 618 AddMessageHandler((handler)->Attach(this));
619 619
620 // The handler's init will determine whether we show the error html page. 620 // The handler's init will determine whether we show the error html page.
621 ChromeWebUIDataSource* html_source = 621 ChromeWebUIDataSource* html_source =
622 CreateBugReportUIHTMLSource(handler->Init()); 622 CreateBugReportUIHTMLSource(handler->Init());
623 623
624 // Set up the chrome://bugreport/ source. 624 // Set up the chrome://bugreport/ source.
625 Profile* profile = Profile::FromBrowserContext(tab->browser_context()); 625 Profile* profile = Profile::FromBrowserContext(tab->browser_context());
626 profile->GetChromeURLDataManager()->AddDataSource(html_source); 626 profile->GetChromeURLDataManager()->AddDataSource(html_source);
627 } 627 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/active_downloads_ui.cc ('k') | chrome/browser/ui/webui/chrome_web_ui.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698