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

Side by Side Diff: chrome/browser/ui/webui/options/reset_profile_settings_handler.cc

Issue 316963002: Move branding information out of google_util (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix for Windows Created 6 years, 6 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
« no previous file with comments | « chrome/browser/signin/signin_promo.cc ('k') | chrome/browser/upgrade_detector_impl.cc » ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/options/reset_profile_settings_handler.h" 5 #include "chrome/browser/ui/webui/options/reset_profile_settings_handler.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/metrics/histogram.h" 9 #include "base/metrics/histogram.h"
10 #include "base/prefs/pref_service.h" 10 #include "base/prefs/pref_service.h"
11 #include "base/strings/string16.h" 11 #include "base/strings/string16.h"
12 #include "base/values.h" 12 #include "base/values.h"
13 #include "chrome/browser/google/google_util.h" 13 #include "chrome/browser/google/google_brand.h"
14 #include "chrome/browser/profile_resetter/automatic_profile_resetter.h" 14 #include "chrome/browser/profile_resetter/automatic_profile_resetter.h"
15 #include "chrome/browser/profile_resetter/automatic_profile_resetter_factory.h" 15 #include "chrome/browser/profile_resetter/automatic_profile_resetter_factory.h"
16 #include "chrome/browser/profile_resetter/brandcode_config_fetcher.h" 16 #include "chrome/browser/profile_resetter/brandcode_config_fetcher.h"
17 #include "chrome/browser/profile_resetter/brandcoded_default_settings.h" 17 #include "chrome/browser/profile_resetter/brandcoded_default_settings.h"
18 #include "chrome/browser/profile_resetter/profile_resetter.h" 18 #include "chrome/browser/profile_resetter/profile_resetter.h"
19 #include "chrome/browser/profile_resetter/resettable_settings_snapshot.h" 19 #include "chrome/browser/profile_resetter/resettable_settings_snapshot.h"
20 #include "chrome/browser/profiles/profile.h" 20 #include "chrome/browser/profiles/profile.h"
21 #include "chrome/common/pref_names.h" 21 #include "chrome/common/pref_names.h"
22 #include "chrome/common/url_constants.h" 22 #include "chrome/common/url_constants.h"
23 #include "content/public/browser/user_metrics.h" 23 #include "content/public/browser/user_metrics.h"
24 #include "content/public/browser/web_ui.h" 24 #include "content/public/browser/web_ui.h"
25 #include "grit/generated_resources.h" 25 #include "grit/generated_resources.h"
26 #include "ui/base/l10n/l10n_util.h" 26 #include "ui/base/l10n/l10n_util.h"
27 27
28 namespace options { 28 namespace options {
29 29
30 ResetProfileSettingsHandler::ResetProfileSettingsHandler() 30 ResetProfileSettingsHandler::ResetProfileSettingsHandler()
31 : automatic_profile_resetter_(NULL), has_shown_confirmation_dialog_(false) { 31 : automatic_profile_resetter_(NULL), has_shown_confirmation_dialog_(false) {
32 google_util::GetBrand(&brandcode_); 32 google_brand::GetBrand(&brandcode_);
33 } 33 }
34 34
35 ResetProfileSettingsHandler::~ResetProfileSettingsHandler() {} 35 ResetProfileSettingsHandler::~ResetProfileSettingsHandler() {}
36 36
37 void ResetProfileSettingsHandler::InitializeHandler() { 37 void ResetProfileSettingsHandler::InitializeHandler() {
38 Profile* profile = Profile::FromWebUI(web_ui()); 38 Profile* profile = Profile::FromWebUI(web_ui());
39 resetter_.reset(new ProfileResetter(profile)); 39 resetter_.reset(new ProfileResetter(profile));
40 automatic_profile_resetter_ = 40 automatic_profile_resetter_ =
41 AutomaticProfileResetterFactory::GetForBrowserContext(profile); 41 AutomaticProfileResetterFactory::GetForBrowserContext(profile);
42 } 42 }
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 Profile::FromWebUI(web_ui()), 212 Profile::FromWebUI(web_ui()),
213 *setting_snapshot_); 213 *setting_snapshot_);
214 base::DictionaryValue feedback_info; 214 base::DictionaryValue feedback_info;
215 feedback_info.Set("feedbackInfo", list.release()); 215 feedback_info.Set("feedbackInfo", list.release());
216 web_ui()->CallJavascriptFunction( 216 web_ui()->CallJavascriptFunction(
217 "ResetProfileSettingsOverlay.setFeedbackInfo", 217 "ResetProfileSettingsOverlay.setFeedbackInfo",
218 feedback_info); 218 feedback_info);
219 } 219 }
220 220
221 } // namespace options 221 } // namespace options
OLDNEW
« no previous file with comments | « chrome/browser/signin/signin_promo.cc ('k') | chrome/browser/upgrade_detector_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698