diff options
author | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-06-21 03:05:19 +0000 |
---|---|---|
committer | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-06-21 03:05:19 +0000 |
commit | 147ff124dd90f6d70f203cfe5c08816e3b533392 (patch) | |
tree | e34901e78e69bb1824d91e066cf6d2ef32f28daa | |
parent | 398206ce0943c935a8da55d382e60e7be16099cf (diff) | |
download | chromium_src-147ff124dd90f6d70f203cfe5c08816e3b533392.zip chromium_src-147ff124dd90f6d70f203cfe5c08816e3b533392.tar.gz chromium_src-147ff124dd90f6d70f203cfe5c08816e3b533392.tar.bz2 |
Remove deprecated version of file_util::EndsWithSeparator.
BUG=24672
TEST=out/Debug/base_unittests
Review URL: http://codereview.chromium.org/2842015
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@50330 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | base/file_util.cc | 7 | ||||
-rw-r--r-- | base/file_util_deprecated.h | 3 |
2 files changed, 2 insertions, 8 deletions
diff --git a/base/file_util.cc b/base/file_util.cc index 5ce4456..bae6535 100644 --- a/base/file_util.cc +++ b/base/file_util.cc @@ -358,7 +358,7 @@ void AppendToPath(std::wstring* path, const std::wstring& new_ending) { return; // Don't crash in this function in release builds. } - if (!EndsWithSeparator(*path)) + if (!EndsWithSeparator(FilePath(*path))) path->push_back(FilePath::kSeparators[0]); path->append(new_ending); } @@ -373,9 +373,6 @@ bool CopyDirectory(const std::wstring& from_path, const std::wstring& to_path, bool Delete(const std::wstring& path, bool recursive) { return Delete(FilePath::FromWStringHack(path), recursive); } -bool EndsWithSeparator(const std::wstring& path) { - return EndsWithSeparator(FilePath::FromWStringHack(path)); -} std::wstring GetFileExtensionFromPath(const std::wstring& path) { FilePath::StringType extension = GetFileExtensionFromPath(FilePath::FromWStringHack(path)); @@ -386,7 +383,7 @@ std::wstring GetFileExtensionFromPath(const std::wstring& path) { #endif } std::wstring GetFilenameFromPath(const std::wstring& path) { - if (path.empty() || EndsWithSeparator(path)) + if (path.empty() || EndsWithSeparator(FilePath::FromWStringHack(path))) return std::wstring(); return FilePath::FromWStringHack(path).BaseName().ToWStringHack(); diff --git a/base/file_util_deprecated.h b/base/file_util_deprecated.h index 28de811..6eae211 100644 --- a/base/file_util_deprecated.h +++ b/base/file_util_deprecated.h @@ -17,9 +17,6 @@ namespace file_util { -bool EndsWithSeparator(std::wstring* path); -bool EndsWithSeparator(const std::wstring& path); - // Use FilePath::DirName instead. void UpOneDirectory(std::wstring* dir); // Use FilePath::DirName instead. |