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

Unified Diff: chrome/browser/ui/views/download/download_feedback_dialog_view.cc

Issue 2418813002: [Reland] Refactoring of SBER preference usage (Closed)
Patch Set: Sync Created 4 years, 2 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 | « chrome/browser/ui/BUILD.gn ('k') | chrome/browser/ui/views/download/download_item_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/download/download_feedback_dialog_view.cc
diff --git a/chrome/browser/ui/views/download/download_feedback_dialog_view.cc b/chrome/browser/ui/views/download/download_feedback_dialog_view.cc
index a8725bc140a365132fd4961e718440c5530908bc..4c11aec1817f728ddbc236f001b9ae2cf89267bb 100644
--- a/chrome/browser/ui/views/download/download_feedback_dialog_view.cc
+++ b/chrome/browser/ui/views/download/download_feedback_dialog_view.cc
@@ -13,6 +13,7 @@
#include "chrome/grit/generated_resources.h"
#include "components/constrained_window/constrained_window_views.h"
#include "components/prefs/pref_service.h"
+#include "components/safe_browsing_db/safe_browsing_prefs.h"
#include "components/strings/grit/components_strings.h"
#include "content/public/browser/page_navigator.h"
#include "ui/base/l10n/l10n_util.h"
@@ -46,7 +47,7 @@ void DownloadFeedbackDialogView::Show(
const UserDecisionCallback& callback) {
// This dialog should only be shown if it hasn't been shown before.
DCHECK(!profile->GetPrefs()->HasPrefPath(
- prefs::kSafeBrowsingExtendedReportingEnabled));
+ safe_browsing::GetExtendedReportingPrefName()));
// Only one dialog should be shown at a time, so check to see if another one
// is open. If another one is open, treat this parallel call as if reporting
@@ -101,8 +102,8 @@ base::string16 DownloadFeedbackDialogView::GetDialogButtonLabel(
}
bool DownloadFeedbackDialogView::OnButtonClicked(bool accepted) {
- profile_->GetPrefs()->SetBoolean(prefs::kSafeBrowsingExtendedReportingEnabled,
- accepted);
+ profile_->GetPrefs()->SetBoolean(
+ safe_browsing::GetExtendedReportingPrefName(), accepted);
DialogStatusData* data =
static_cast<DialogStatusData*>(profile_->GetUserData(kDialogStatusKey));
DCHECK(data);
« no previous file with comments | « chrome/browser/ui/BUILD.gn ('k') | chrome/browser/ui/views/download/download_item_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698