diff options
author | blundell@chromium.org <blundell@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-06-12 14:29:02 +0000 |
---|---|---|
committer | blundell@chromium.org <blundell@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-06-12 14:29:02 +0000 |
commit | 9b5b1d60209fd342960797723e9ad108d49e6cad (patch) | |
tree | 032759d7e9c9f1ab207d6c28308b1c788416e69b /chrome/browser/prefs/session_startup_pref.cc | |
parent | 820fb1ed762a001b82ecc227f24d6dbde8ea6b17 (diff) | |
download | chromium_src-9b5b1d60209fd342960797723e9ad108d49e6cad.zip chromium_src-9b5b1d60209fd342960797723e9ad108d49e6cad.tar.gz chromium_src-9b5b1d60209fd342960797723e9ad108d49e6cad.tar.bz2 |
Componentize URLFixerUpper.
This CL moves URLFixerUpper into a new url_fixer component to allow this code
to be shared by the iOS port. At the present time the component contains some
minor Chrome-specific logic. Specifically, it rewrites about:// to chrome://
and uses about:// version as the default about:// host. We decided not to
abstract this logic at this time, as the only embedders wishing to use this
component are ports of Chrome. However, if there comes to be a non-Chrome
embedder that wishes to use this component, this behavior could easily be
generalized (e.g., by exposing the variables that are used for these purposes
in the header file to allow the embedder to customize them).
BUG=373229
R=jam@chromium.org
TBR=mmenke
NOTREECHECKS=true
Review URL: https://codereview.chromium.org/320253004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@276672 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/prefs/session_startup_pref.cc')
-rw-r--r-- | chrome/browser/prefs/session_startup_pref.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/chrome/browser/prefs/session_startup_pref.cc b/chrome/browser/prefs/session_startup_pref.cc index b709585..9bc0c55 100644 --- a/chrome/browser/prefs/session_startup_pref.cc +++ b/chrome/browser/prefs/session_startup_pref.cc @@ -13,9 +13,9 @@ #include "base/values.h" #include "base/version.h" #include "chrome/browser/profiles/profile.h" -#include "chrome/common/net/url_fixer_upper.h" #include "chrome/common/pref_names.h" #include "components/pref_registry/pref_registry_syncable.h" +#include "components/url_fixer/url_fixer.h" #if defined(OS_MACOSX) #include "chrome/browser/ui/cocoa/window_restore_utils.h" @@ -54,7 +54,7 @@ void URLListToPref(const base::ListValue* url_list, SessionStartupPref* pref) { for (size_t i = 0; i < url_list->GetSize(); ++i) { std::string url_text; if (url_list->GetString(i, &url_text)) { - GURL fixed_url = URLFixerUpper::FixupURL(url_text, std::string()); + GURL fixed_url = url_fixer::FixupURL(url_text, std::string()); pref->urls.push_back(fixed_url); } } |