diff options
author | engedy@chromium.org <engedy@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-12-04 04:48:02 +0000 |
---|---|---|
committer | engedy@chromium.org <engedy@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-12-04 04:48:02 +0000 |
commit | ec3b6b846e1c53881d989906e6d3234826121be5 (patch) | |
tree | 0439abbf97094f58c64752bfa2fe9c5b4aa4b997 /chrome/browser/profile_resetter | |
parent | e316d418b470cfc60f6219ae44d5ad64090134e6 (diff) | |
download | chromium_src-ec3b6b846e1c53881d989906e6d3234826121be5.zip chromium_src-ec3b6b846e1c53881d989906e6d3234826121be5.tar.gz chromium_src-ec3b6b846e1c53881d989906e6d3234826121be5.tar.bz2 |
Added the Profile Settings Reset sub-page of settings to url_constants.cc and builtin_provider.cc; and cleaned up accessing it from ProfileResetGlobalError.
This makes the feature reachable through the Omnibox; and allows for nicer disposition: the sub-page will open in-place when the NTP is the current tab, or in the existing settings page if one is already open.
BUG=298036
Review URL: https://codereview.chromium.org/101833002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@238572 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/profile_resetter')
-rw-r--r-- | chrome/browser/profile_resetter/profile_reset_global_error.cc | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/chrome/browser/profile_resetter/profile_reset_global_error.cc b/chrome/browser/profile_resetter/profile_reset_global_error.cc index 5a2cd06..ed31929 100644 --- a/chrome/browser/profile_resetter/profile_reset_global_error.cc +++ b/chrome/browser/profile_resetter/profile_reset_global_error.cc @@ -10,19 +10,17 @@ #include "chrome/browser/profile_resetter/automatic_profile_resetter_factory.h" #include "chrome/browser/profiles/profile.h" #include "chrome/browser/ui/browser.h" +#include "chrome/browser/ui/chrome_pages.h" #include "chrome/browser/ui/global_error/global_error_service.h" #include "chrome/browser/ui/global_error/global_error_service_factory.h" #include "chrome/browser/ui/profile_reset_bubble.h" +#include "chrome/common/url_constants.h" #include "grit/chromium_strings.h" #include "grit/generated_resources.h" #include "ui/base/l10n/l10n_util.h" namespace { -// The URL that leads directly to the WebUI reset dialog in the settings page. -const char kResetProfileSettingsURL[] = - "chrome://settings/resetProfileSettings"; - base::TimeDelta GetPromptDelayHistogramMaximum() { return base::TimeDelta::FromDays(7); } @@ -71,9 +69,7 @@ string16 ProfileResetGlobalError::MenuItemLabel() { } void ProfileResetGlobalError::ExecuteMenuItem(Browser* browser) { - browser->OpenURL(content::OpenURLParams( - GURL(kResetProfileSettingsURL), content::Referrer(), - NEW_FOREGROUND_TAB, content::PAGE_TRANSITION_LINK, false)); + chrome::ShowSettingsSubPage(browser, chrome::kResetProfileSettingsSubPage); } bool ProfileResetGlobalError::HasBubbleView() { return true; } |